From: <no...@at...> - 2005-08-21 02:50:57
|
The following issue has been updated: Updater: Gavin King (mailto:ga...@hi...) Date: Sat, 20 Aug 2005 9:49 PM Comment: Correct, and this is not a bug. Changes: type changed from Bug to New Feature --------------------------------------------------------------------- For a full history of the issue, see: http://opensource.atlassian.com/projects/hibernate/browse/HHH-892?page=history --------------------------------------------------------------------- View the issue: http://opensource.atlassian.com/projects/hibernate/browse/HHH-892 Here is an overview of the issue: --------------------------------------------------------------------- Key: HHH-892 Summary: HQL parser does not resolve alias in ORDER BY clause Type: New Feature Status: Unassigned Priority: Major Original Estimate: Unknown Time Spent: Unknown Remaining: Unknown Project: Hibernate3 Versions: 3.0.5 Assignee: Reporter: Guido Laures Created: Sat, 20 Aug 2005 8:26 PM Updated: Sat, 20 Aug 2005 9:49 PM Environment: Hibernate 3.0.5, MySQL, Tomcat Description: When using an alias for an ORDER BY clause this is not always correctly resolved. Example: SELECT SUM(A.x) AS mySum FROM MyClass AS A GROUP BY A.y ORDER BY mySum does not work because "mySum" is not resolved in the ORDER BY clause which results in an exception telling that mySum is an unknown column. Workaround (not to say "hack") is using: SELECT SUM(A.x) AS mySum FROM MyClass AS A GROUP BY A.y ORDER BY col_0_0_ --------------------------------------------------------------------- JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira |