[jboss-user] [JBoss Tools] - Hibernate tool - HQL query fails with LazyInitializationException

Stephanie Smith do-not-reply at jboss.com
Tue May 1 11:38:36 EDT 2012


Stephanie Smith [https://community.jboss.org/people/Stephanie.Smith] created the discussion

"Hibernate tool - HQL query fails with LazyInitializationException"

To view the discussion, visit: https://community.jboss.org/message/733177#733177

--------------------------------------------------------------
I am using the hibernate eclipse plugin. I have the session and connection information defined (and mappings).
When I issue the HQL query, I always get a LazyInitializationException.

  
2012-05-01 11:30:21,149 ERROR main org.hibernate.LazyInitializationException - failed to lazily initialize a collection of role: com.mypackage.HibProcess.subprocesses, no session or session was closed
org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.mypackage..HibProcess.subprocesses, no session or session was closed


Any ideas how i can avoid this?
I am using similar configuration/properties that I used previously without error (but was a different database).

Thanks
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/733177#733177]

Start a new discussion in JBoss Tools at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2128]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120501/afa5852a/attachment.html 


More information about the jboss-user mailing list