-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Unindexed collection exception in HQL query
PostPosted: Tue Oct 31, 2006 3:30 pm 
Beginner
Beginner

Joined: Mon Dec 06, 2004 4:20 pm
Posts: 34
Hi all,

I am trying to execute an HQL query and am getting the following exception:

unindexed collection before []: householdm1_.participants

The query itself is as follows:

from HouseholdMember member1 where member1.household.householdId in (select hh.householdId from Household hh where hh.householdId in (select t1.householdId from Household t1 join t1.householdMembers as member where t1.investigatorIndicator = :investigator and (member.typeCode = '1' OR member.typeCode IS NULL) and soundex(member.firstName) = soundex(:firstName) join member.participants as participant ) where rownum <= 51) order by member1.household.householdId, member1.typeCode, member1.lastName, member1.firstName, member1.middleInitial

A Household has one or more members, a member has one or more participants.

The actual SQL is not being shown in the log. Does anyone have any ideas what is causing this??

Hibernate version: 3

Full stack trace of any exception that occurs:
Caused by: org.hibernate.QueryException: unindexed collection before []: householdm1_.participants [from gov.mass.eos.business.model.ce.household.HouseholdMember member1 where member1.household.householdId in (select hh.householdId from gov.mass.eos.business.model.ce.household.Household hh where hh.householdId in (select t1.householdId from gov.mass.eos.business.model.ce.household.Household t1 join t1.householdMembers as member where t1.investigatorIndicator = :investigator and (member.typeCode = '1' OR member.typeCode IS NULL) and soundex(member.firstName) = soundex(:firstName) join member.participants as participant ) where rownum <= 51) order by member1.household.householdId, member1.typeCode, member1.lastName, member1.firstName, member1.middleInitial ]
at org.hibernate.hql.classic.PathExpressionParser.prepareForIndex(PathExpressionParser.java:331)
at org.hibernate.hql.classic.PathExpressionParser.end(PathExpressionParser.java:315)
at org.hibernate.hql.classic.WhereParser.doPathExpression(WhereParser.java:349)
at org.hibernate.hql.classic.WhereParser.doToken(WhereParser.java:382)
at org.hibernate.hql.classic.WhereParser.token(WhereParser.java:263)
at org.hibernate.hql.classic.ClauseParser.token(ClauseParser.java:86)
at org.hibernate.hql.classic.PreprocessingParser.token(PreprocessingParser.java:108)
at org.hibernate.hql.classic.ParserHelper.parse(ParserHelper.java:28)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:176)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:139)
at org.hibernate.hql.classic.WhereParser.token(WhereParser.java:226)
at org.hibernate.hql.classic.ClauseParser.token(ClauseParser.java:86)
at org.hibernate.hql.classic.PreprocessingParser.token(PreprocessingParser.java:108)
at org.hibernate.hql.classic.ParserHelper.parse(ParserHelper.java:28)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:176)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:139)
at org.hibernate.hql.classic.WhereParser.token(WhereParser.java:226)
at org.hibernate.hql.classic.ClauseParser.token(ClauseParser.java:86)
at org.hibernate.hql.classic.PreprocessingParser.token(PreprocessingParser.java:108)
at org.hibernate.hql.classic.ParserHelper.parse(ParserHelper.java:28)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:176)
at org.hibernate.hql.classic.QueryTranslatorImpl.compile(QueryTranslatorImpl.java:152)
at org.hibernate.impl.SessionFactoryImpl.getQuery(SessionFactoryImpl.java:427)
at org.hibernate.impl.SessionImpl.getQueries(SessionImpl.java:884)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:834)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:74)
at gov.mass.eos.persistence.HibernatePersistenceManager.executeHQLQuery(HibernatePersistenceManager.java:446)


Name and version of the database you are using:Oracle 9


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.