Fix syntax error when join unrelated entity with discriminator entity#6812
Merged
lcobucci merged 1 commit intoDec 17, 2017
Merged
Conversation
This was referenced Nov 15, 2017
c2274d2 to
32c125d
Compare
lcobucci
approved these changes
Dec 17, 2017
Member
lcobucci
left a comment
There was a problem hiding this comment.
I've applied some small changes to reduce the complexity and it LGTM 👍
Member
|
@Deltachaos 🚢 and backported! Thanks! |
BourotBenjamin
added a commit
to BourotBenjamin/doctrine2
that referenced
this pull request
Dec 21, 2017
v2.5.14 This version backports bugfixes related to the generation of queries with joins and configuration of the result set cache profile of a query. Total issues resolved: **2** Bug - [6748: Fix missing null check on `AbstractQuery#setResultCacheProfile()`](doctrine#6748) thanks to @KonstantinKuklin - [6812: Fix syntax error when join unrelated entity with discriminator entity](doctrine#6812) thanks to @Deltachaos
21skills
added a commit
to 21skills/orm
that referenced
this pull request
Jan 27, 2021
Continuation of a problem from doctrine#6812 The same problem appears if you add WITH condition to the joined entity with discriminator
greg0ire
pushed a commit
to piowin/orm
that referenced
this pull request
Jul 23, 2021
Continuation of a problem from doctrine#6812 The same problem appears if you add WITH condition to the joined entity with discriminator
greg0ire
pushed a commit
to piowin/orm
that referenced
this pull request
Jul 23, 2021
Continuation of a problem from doctrine#6812 The same problem appears if you add WITH condition to the joined entity with discriminator
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When joining a unrelated entity with a discriminator the join contains the table name and alias in brackets which is a syntax error (at least in SQL Server).
Exmaple:
Results in:
After the fix it results in:
I have created #6811 PR for backporting this to the 2.5 branch as well.