DDC-135: With/on extra join clauses are not yet processed properly by SqlWalker #167

Closed
opened 2026-01-22 12:29:23 +01:00 by admin · 11 comments
Owner

Originally created by @doctrinebot on GitHub (Nov 10, 2009).

Originally assigned to: @beberlei on GitHub.

Jira issue originally created by user reinier.kip:

Reference thread: http://groups.google.com/group/doctrine-user/browse_thread/thread/5f3e01818cf30878

Criteria specified with QueryBuilder::leftJoin() do not appear in the native query. Looks like the with/on extra join clauses are not yet processed
properly by the SqlWalker that constructs the SQL+parameters.

Originally created by @doctrinebot on GitHub (Nov 10, 2009). Originally assigned to: @beberlei on GitHub. Jira issue originally created by user reinier.kip: Reference thread: http://groups.google.com/group/doctrine-user/browse_thread/thread/5f3e01818cf30878 Criteria specified with QueryBuilder::leftJoin() do not appear in the native query. Looks like the with/on extra join clauses are not yet processed properly by the SqlWalker that constructs the SQL+parameters.
admin added the Bug label 2026-01-22 12:29:23 +01:00
admin closed this issue 2026-01-22 12:29:24 +01:00
Author
Owner
@doctrinebot commented on GitHub (Nov 10, 2009): - relates to [DDC-177: Throw exception if ON/WITH join condition override/extension is used on a fetch-join with HYDRATE_OBJECT](http://www.doctrine-project.org/jira/browse/DDC-177) - is referenced by [DDC-176: Query::iterate is broken when using JOIN](http://www.doctrine-project.org/jira/browse/DDC-176)
Author
Owner

@doctrinebot commented on GitHub (Dec 9, 2009):

Comment created by @guilhermeblanco:

They talk about the same thing.

@doctrinebot commented on GitHub (Dec 9, 2009): Comment created by @guilhermeblanco: They talk about the same thing.
Author
Owner

@doctrinebot commented on GitHub (Feb 13, 2010):

Comment created by @beberlei:

Patch that fixes both DDC-135 but restricts it by the assumptions of DDC-177, namely not allowing to fetch join a LEFT JOIN .. ON/WITH clause

@doctrinebot commented on GitHub (Feb 13, 2010): Comment created by @beberlei: Patch that fixes both [DDC-135](http://www.doctrine-project.org/jira/browse/DDC-135) but restricts it by the assumptions of [DDC-177](http://www.doctrine-project.org/jira/browse/DDC-177), namely not allowing to fetch join a LEFT JOIN .. ON/WITH clause
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by romanb:

@Benjamin: Thats a good start but its not yet what its supposed to be. WITH *appends* to the join condition whereas ON overrides it. In the patch I only see ON implemented and it behaves like WITH.

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by romanb: @Benjamin: Thats a good start but its not yet what its supposed to be. WITH **appends\* to the join condition whereas ON *overrides** it. In the patch I only see ON implemented and it behaves like WITH.
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by romanb:

I see you implemented WITH also, but they are supposed to produce different SQL. ON overrides, WITH appends.

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by romanb: I see you implemented WITH also, but they are supposed to produce different SQL. ON overrides, WITH appends.
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by romanb:

@Benjamin: Btw. I think we should only implement WITH for now. ON is a bit too scary for me and I'd like to see more usecases first.

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by romanb: @Benjamin: Btw. I think we should only implement WITH for now. ON is a bit too scary for me and I'd like to see more usecases first.
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by @beberlei:

Ah now i understand, i didn't get the difference ;-)

I will strip down the patch to WITH then and handle it appropriately

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by @beberlei: Ah now i understand, i didn't get the difference ;-) I will strip down the patch to WITH then and handle it appropriately
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by @beberlei:

The way i implemented ON it worked as WITH anyways.

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by @beberlei: The way i implemented ON it worked as WITH anyways.
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Comment created by @beberlei:

Fixed, WITH clauses are processed correctly now. ON clauses throw an exception.

@doctrinebot commented on GitHub (Feb 14, 2010): Comment created by @beberlei: Fixed, WITH clauses are processed correctly now. ON clauses throw an exception.
Author
Owner

@doctrinebot commented on GitHub (Feb 14, 2010):

Issue was closed with resolution "Fixed"

@doctrinebot commented on GitHub (Feb 14, 2010): Issue was closed with resolution "Fixed"
Author
Owner

@doctrinebot commented on GitHub (Dec 13, 2015):

Imported 1 attachments from Jira into https://gist.github.com/fc2f5943c39332f7b721

@doctrinebot commented on GitHub (Dec 13, 2015): Imported 1 attachments from Jira into https://gist.github.com/fc2f5943c39332f7b721 - [10366_ddc135_ddc177.patch](https://gist.github.com/fc2f5943c39332f7b721#file-10366_ddc135_ddc177-patch)
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#167