[hibernate-issues] [JIRA] (HHH-14045) Unable to group by "to_char" function

Christian Beikov (JIRA) jira at hibernate.atlassian.net
Fri Jul 24 08:38:10 EDT 2020


Christian Beikov ( https://hibernate.atlassian.net/secure/ViewProfile.jspa?accountId=557058%3A0222998d-a0c8-4789-91ec-6a92d10dfb9a ) *commented* on HHH-14045 ( https://hibernate.atlassian.net/browse/HHH-14045?atlOrigin=eyJpIjoiYTJmMjlmNmRmYjcxNGNmNGJlMTdiNjg1MmEzNmI0YzUiLCJwIjoiaiJ9 )

Re: Unable to group by "to_char" function ( https://hibernate.atlassian.net/browse/HHH-14045?atlOrigin=eyJpIjoiYTJmMjlmNmRmYjcxNGNmNGJlMTdiNjg1MmEzNmI0YzUiLCJwIjoiaiJ9 )

The support for using an alias in the group by was added in 5.4.4 I think, but it will only work with JPQL/HQL, not through the Criteria API. Anyway, the issue you are having is that the JPA Criteria Literal is rendered as parameter. This can be turned off by setting hibernate.criteria.literal_handling_mode to INLINE which IMO should be the default.

( https://hibernate.atlassian.net/browse/HHH-14045#add-comment?atlOrigin=eyJpIjoiYTJmMjlmNmRmYjcxNGNmNGJlMTdiNjg1MmEzNmI0YzUiLCJwIjoiaiJ9 ) Add Comment ( https://hibernate.atlassian.net/browse/HHH-14045#add-comment?atlOrigin=eyJpIjoiYTJmMjlmNmRmYjcxNGNmNGJlMTdiNjg1MmEzNmI0YzUiLCJwIjoiaiJ9 )

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.core&referrer=utm_source%3DNotificationLink%26utm_medium%3DEmail ) or iOS ( https://itunes.apple.com/app/apple-store/id1006972087?pt=696495&ct=EmailNotificationLink&mt=8 ) This message was sent by Atlassian Jira (v1001.0.0-SNAPSHOT#100140- sha1:5d840a8 )
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/hibernate-issues/attachments/20200724/b73fe917/attachment.html 


More information about the hibernate-issues mailing list