[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-465?page=co...
]
sridhar paladugu commented on HHH-465:
--------------------------------------
We are working on a large project using Hibernate, and really would like to see this issue
fixed.
I do not have problem in using some oracle native functions in order by clause in HQL
except "NULLS LAST".
Hibernate while generating oracle sql ignoring th key word (NULLS LAST) and generating the
SQL without the keyword present in order by clause.
Following is a sample query i am using
HQL: " select me.name from MyEntity me order by me.name NULLS LAST"
generated SQL: select TBL.NAME FROM MyTable TBL ORDER BY TBL.NAME.
Thanks
Sridhar
order by nulls first / last
---------------------------
Key: HHH-465
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-465
Project: Hibernate3
Type: Improvement
Components: core
Versions: 3.0.3
Reporter: Anthony Patricio
Priority: Minor
support of nulls first / last in order clause
"NULLS LAST" is part of the SQL 99 standard.
The syntax is as follows:
ORDER BY [COLUMN NAME] [ASC | DESC] [NULLS FIRST | NULLS LAST]
In different DBs, the sorting of nulls relative to other values is handled differently.
PostgreSQL - Nulls are considered HIGHER than non-nulls.
DB2 - Higher
MSSQL - Lower
MySQL - Lower
Oracle - Higher
The following DBs have supported this functionality:
DB2 V7
Oracle 9i
PostgreSQL, MySQL, SQLServer do not appear to support this from what I can gather.
see
http://forum.hibernate.org/viewtopic.php?t=942176&start=0&postday...
--
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....
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira