From 21bab7bcbb5fa2e696b2c310fef296493b68c1bf Mon Sep 17 00:00:00 2001 From: zYne Date: Tue, 31 Jul 2007 19:58:44 +0000 Subject: [PATCH] --- .../en/dql-doctrine-query-language/join-syntax.txt | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/manual/new/docs/en/dql-doctrine-query-language/join-syntax.txt b/manual/new/docs/en/dql-doctrine-query-language/join-syntax.txt index 177cfe267..cd8a1d85f 100644 --- a/manual/new/docs/en/dql-doctrine-query-language/join-syntax.txt +++ b/manual/new/docs/en/dql-doctrine-query-language/join-syntax.txt @@ -61,3 +61,15 @@ SQL: SELECT u.id AS u__id, p.id AS p__id FROM User u LEFT JOIN Phonenumber p ON u.id = p.user_id AND u.id = 2 +The Doctrine_Query API offers two convenience methods for adding JOINS. These are called innerJoin() and leftJoin(), which usage should be quite intuitive as shown below: + + +$q = new Doctrine_Query(); +$q->from('User u') + ->leftJoin('u.Group g') + ->innerJoin('u.Phonenumber p WITH u.id > 3') + ->leftJoin('u.Email e'); + +$users = $q->execute(); + +