[DDC-1884] leftJoin via composite key part not hydrated if joining table solely consists of identifiers Created: 20/Jun/12 Updated: 10/Aug/13 Resolved: 10/Aug/13
|Project:||Doctrine 2 - ORM|
|Fix Version/s:||2.4, 2.3.5|
|Reporter:||Sander Coolen||Assignee:||Benjamin Eberlei|
Suppose I have the following entities:
And want to query for Cars that a Driver drove in:
When I started doing some testing I found out I get a different result when I add a third column to the DriverRide table that isn't part of the composite primary key.
When I removed the composite key and used an auto-generated id-column, everything worked as expected.
Some test data you might want to use:
|Comment by Benjamin Eberlei [ 05/Jul/12 ]|
Can you update to at least 2.2.1 and try again, because this fix here http://www.doctrine-project.org/jira/browse/DDC-1652 look like it could be related to your problem.
|Comment by Sander Coolen [ 07/Jul/12 ]|
We're already using the 2.2.x-dev package. It does look similar to
|Comment by Sander Coolen [ 08/Jul/12 ]|
Added testcase on 2.1.x (not the right one unfortunately) branch: https://github.com/doctrine/doctrine2/pull/395
BTW I was adding said testcase on master and got an error similar to
|Comment by Benjamin Eberlei [ 09/May/13 ]|
I upgraded the testcase to master locally, and it seems to fail on Array hydration only now, with a notice:
I remember fixing something similar for ObjectHydration (which works for your testcases). Will investigate more when I have time.