Christian Beikov (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
) *created* an issue
Hibernate ORM (
https://hibernate.atlassian.net/browse/HHH?atlOrigin=eyJpIjoiMDJiMTgyMjdl...
) / Improvement (
https://hibernate.atlassian.net/browse/HHH-16789?atlOrigin=eyJpIjoiMDJiMT...
) HHH-16789 (
https://hibernate.atlassian.net/browse/HHH-16789?atlOrigin=eyJpIjoiMDJiMT...
) Improve error message for use of limit without order by in subquery (
https://hibernate.atlassian.net/browse/HHH-16789?atlOrigin=eyJpIjoiMDJiMT...
)
Issue Type: Improvement Affects Versions: 6.2.4 Assignee: Unassigned Components:
hibernate-core Created: 13/Jun/2023 07:53 AM Fix Versions: 6.wishlist Priority: Major
Reporter: Christian Beikov (
https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%...
)
A query like the following fails with an error that is not helpful:
select 1 from MyEntity where 1 = (select 1 from MyEntity e limit 1)
The error is a missing order by clause, but the parsing fails with “no viable
alternative”. We should always parse this and rather throw a meaningful error during
visitation.
(
https://hibernate.atlassian.net/browse/HHH-16789#add-comment?atlOrigin=ey...
) Add Comment (
https://hibernate.atlassian.net/browse/HHH-16789#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#100225- sha1:956085d )