[hibernate-issues] [Hibernate-JIRA] Closed: (HHH-2840) Externalizing named HQL queries with DML is impossible

Steve Ebersole (JIRA) noreply at atlassian.com
Wed Oct 3 01:59:24 EDT 2007


     [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-2840?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Steve Ebersole closed HHH-2840.
-------------------------------

    Resolution: Cannot Reproduce

> Externalizing named HQL queries with DML is impossible
> ------------------------------------------------------
>
>                 Key: HHH-2840
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2840
>             Project: Hibernate3
>          Issue Type: Bug
>         Environment: Hibernate Core 3.2.5
>            Reporter: Dimitri Lubenskyy
>
> Externalizing the update HQL query into the XML file e.g.
> ....
> </class>
> <query name="hqlResetNotificationDatePlc">
>     <![CDATA[update ServiceEvents se set se.notificationNeeded=0 where se.notificationNeeded=1]]>
> </query>    
> </hibernate-mapping>
> Throws the exception:
> org.hibernate.hql.ast.ErrorCounter: line 1:1: unexpected token: hqlResetNotificationDateRc
> line 1:1: unexpected token: hqlResetNotificationDateRc
> 	at org.hibernate.hql.antlr.HqlBaseParser.statement(HqlBaseParser.java:171)
> 	at org.hibernate.hql.ast.QueryTranslatorImpl.parse(QueryTranslatorImpl.java:248)
> 	at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl.java:157)
> 	at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:111)
> 	at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:77)
> 	at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:56)
> 	at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
> 	at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionImpl.java:133)
> 	at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.java:112)
> 	at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623)

-- 
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