Commit a87e4183 authored by zYne's avatar zYne

--no commit message

--no commit message
parent 04d0ffb9
...@@ -876,7 +876,7 @@ class Doctrine_Query2 extends Doctrine_Hydrate2 implements Countable ...@@ -876,7 +876,7 @@ class Doctrine_Query2 extends Doctrine_Hydrate2 implements Countable
. $joinCondition; . $joinCondition;
if ($relation instanceof Doctrine_Relation_Association_Self) { if ($relation instanceof Doctrine_Relation_Association_Self) {
$queryPart .= ' OR ' . $foreignTable . '.' . $table->getIdentifier() . ' = ' $queryPart .= ' OR ' . $foreignAlias . '.' . $table->getIdentifier() . ' = '
. $assocAlias . '.' . $relation->getLocal(); . $assocAlias . '.' . $relation->getLocal();
} }
......
...@@ -58,7 +58,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase ...@@ -58,7 +58,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase
} }
public function testRecordHydrationWorksWithDeeplyNestedStructures() public function testRecordHydrationWorksWithDeeplyNestedStructures()
{ {
$q = new Doctrine_Query(); $q = new Doctrine_Query2();
$q->select('c.*, c2.*, d.*') $q->select('c.*, c2.*, d.*')
->from('Record_Country c')->leftJoin('c.City c2')->leftJoin('c2.District d') ->from('Record_Country c')->leftJoin('c.City c2')->leftJoin('c2.District d')
...@@ -77,7 +77,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase ...@@ -77,7 +77,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase
} }
public function testManyToManyJoinUsesProperTableAliases() public function testManyToManyJoinUsesProperTableAliases()
{ {
$q = new Doctrine_Query(); $q = new Doctrine_Query2();
$q->select('u.name')->from('User u INNER JOIN u.Group g'); $q->select('u.name')->from('User u INNER JOIN u.Group g');
...@@ -86,7 +86,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase ...@@ -86,7 +86,7 @@ class Doctrine_Query_Join_TestCase extends Doctrine_UnitTestCase
public function testSelfReferentialAssociationJoinsAreSupported() public function testSelfReferentialAssociationJoinsAreSupported()
{ {
$q = new Doctrine_Query(); $q = new Doctrine_Query2();
$q->select('e.name')->from('Entity e INNER JOIN e.Entity e2'); $q->select('e.name')->from('Entity e INNER JOIN e.Entity e2');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment