ClassicQueryTranslatorFactory & Custom Functions Doesn't work?
--------------------------------------------------------------
Key: HHH-3954
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-3954
Project: Hibernate Core
Issue Type: Bug
Affects Versions: 3.3.1
Reporter: Sandeep Vaid
I am using hibernate 3.2.1-ga version.
I have extended the DB2Dialect and defined my own function:
registerFunction("svminus1", new NoArgSQLFunction("current time",
Hibernate.TIME, false) );
It is working fine with ASTQueryTranslatorFactory
HQL: select svminus1() from Temp c where c.id=1
SQL: select current time as col_0_0_ from TEMP c0_ where c0_.ID=1
But when i use ClassicQueryTranslatorFactory, it gives me errors:
org.hibernate.QueryException: aggregate function expected before ( in SELECT [select
svminus1() from Temp c where c.id=1]
Why am i getting this error?
--
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