[hibernate-issues] [Hibernate-JIRA] Commented: (HHH-3510) HQL SQLFunction replacement not occuring when HQL text has no parenthesis

Gail Badner (JIRA) noreply at atlassian.com
Mon May 18 18:48:13 EDT 2009


    [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-3510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=33196#action_33196 ] 

Gail Badner commented on HHH-3510:
----------------------------------

I changed the following test to skip the query for SybaseASE15Dialect:
    org.hibernate.test.component.basic.ComponentTest.testComponentQueries()

I also added a "FailureExpected" test that reproduces this issue:
    org.hibernate.test.component.basic.ComponentTest.testComponentQueryMethodNoParensFailureExpected()

I've committed these changes to trunk, Branch_3_3, Branch_3_2, and Branch_3_2_4_SP1_CP.

When this issue is fixed, the check for SybaseASE15Dialect should be removed from ComponentTest.testComponentQueries() and ComponentTest.testComponentQueryMethodNoParensFailureExpected() should be deleted.

> HQL SQLFunction replacement not occuring when HQL text has no parenthesis
> -------------------------------------------------------------------------
>
>                 Key: HHH-3510
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-3510
>             Project: Hibernate Core
>          Issue Type: Bug
>          Components: query-hql
>    Affects Versions: 3.2.4.sp1
>         Environment: Branch_3_2_4_SP1_CP and Sybase 15
>            Reporter: Juraci Paixao Krohling
>            Assignee: Steve Ebersole
>
> Test Case: ComponentTest#testComponentQueries
> Hibernate query "from Employee e where e.person = ('steve', current_timestamp)" should have translated "current_timestamp" to "getdate()" [1]:
> 14:49:11,087 DEBUG SQL:424 - select employee0_.ID as ID1_, employee0_.HIRE_DATE as HIRE2_1_, employee0_.name as name1_, employee0_.dob as dob1_, employee0_.value1 as value5_1_, employee0_.value2 as value6_1_ from T_EMP employee0_ where employee0_.name='steve' and employee0_.dob=current_timestamp
> 14:49:11,535  WARN JDBCExceptionReporter:77 - SQL Error: 207, SQLState: ZZZZZ
> 14:49:11,536 ERROR JDBCExceptionReporter:78 - Invalid column name 'current_timestamp'.
> [1] SybaseDialect, line 58: registerFunction( "current_timestamp", new NoArgSQLFunction("getdate", Hibernate.TIMESTAMP) );

-- 
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
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list