Christian Beikov (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) *created* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiOWE0NmY1MDIw...
) / Bug (
https://hibernate.atlassian.net/browse/HHH-15537?atlOrigin=eyJpIjoiOWE0Nm...
) HHH-15537 (
https://hibernate.atlassian.net/browse/HHH-15537?atlOrigin=eyJpIjoiOWE0Nm...
) Lateral subquery emulation fails on MySQL 5.7 (
https://hibernate.atlassian.net/browse/HHH-15537?atlOrigin=eyJpIjoiOWE0Nm...
)
Issue Type: Bug Affects Versions: 6.1.3 Assignee: Christian Beikov (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) Components: hibernate-core Created: 21/Sep/2022 02:08 AM Fix Versions: 6.1.4 Priority:
Major Reporter: Christian Beikov (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
)
The lateral subquery emulation for MySQL 5.7 currently uses a double nested subquery which
is not supported on MySQL. For a lateral subquery that uses a QuerySpec there is another
possible emulation which is to simply check in the ON condition if a matching result
exists for the correlated subquery i.e. essentially peeling off the double nesting. To
support a QuerySpec that uses limit/offset, which is pretty common for lateral subqueries
(IMO the main reason to use lateral), we have to add an additional predicate that checks
if the amount of rows that come before the currently joined row is between offset and
(offset+limit).
(
https://hibernate.atlassian.net/browse/HHH-15537#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-15537#add-comment?atlOrigin=ey...
)
Get Jira notifications on your phone! Download the Jira Cloud app for Android (
https://play.google.com/store/apps/details?id=com.atlassian.android.jira....
) or iOS (
https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=Em...
) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100207- sha1:a65942b )