[hibernate-issues] [Hibernate-JIRA] Created: (HHH-4491) NPE in HQL subselect
John Hutcheson (JIRA)
noreply at atlassian.com
Mon Oct 12 23:30:43 EDT 2009
NPE in HQL subselect
--------------------
Key: HHH-4491
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-4491
Project: Hibernate Core
Issue Type: Bug
Environment: HIB3.2.3 & 3.2.4 H2 on win32
Reporter: John Hutcheson
this fails:
<code>
select cg, (exists(select caer from nz.org.wpc.crm.dao.CivicrmAclEntityRole$Group as caer
where caer.aclRoleId = :roleId
and caer.entityId = cg.id))
from CivicrmGroup as cg
</code>
exception is
java.lang.NullPointerException
at org.hibernate.hql.ast.ParameterTranslationsImpl.getNamedParameterExpectedType(ParameterTranslationsImpl.java:63)
at org.hibernate.engine.query.HQLQueryPlan.buildParameterMetadata(HQLQueryPlan.java:296)
at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:97)
at org.hibernate.engine.query.HQLQueryPlan.<init>(HQLQueryPlan.java:56)
at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache.java:72)
<B>this works:</B>
<code>
select cg, (exists(select caer from nz.org.wpc.crm.dao.CivicrmAclEntityRole$Group as caer
where caer.aclRoleId = 1
and caer.entityId = cg.id))
from CivicrmGroup as cg
</code>
--
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