wood burning stoves 2.0*
The moose likes Object Relational Mapping and the fly likes org.hibernate.loader.MultipleBagFetchException Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "org.hibernate.loader.MultipleBagFetchException" Watch "org.hibernate.loader.MultipleBagFetchException" New topic
Author

org.hibernate.loader.MultipleBagFetchException

Markus Schmider
Ranch Hand

Joined: Feb 25, 2007
Posts: 100
Hello,

I have the following classes


They are part of a larger Object graph. When I try to run tests I get



What the ....

When I remove fetch=FetchType.EAGER the error disapears.
Curiously when I isolate the two classes in a new project and try to save them I have no problems.
So it appears that in the original project the problem arises from some interaction upstream of Adresse with the FetchEager annotated on the list.

Doing simple things like a unidirectional one-to-many relationship should not be so hard ...

Had anyone similiar problems?

It is a JSE project, my maven dependencies are

 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: org.hibernate.loader.MultipleBagFetchException
 
Similar Threads
Spring3 + JPA 2 + JBoss 6
AnnotationException: : wrong number of column
JPA JSE and JUnit
Hibernate 3 / JPA: Simple Select Query returning ClassCastException
java.lang.NoSuchMethodError: javax.persistence.spi.PersistenceUnitInfo.getValidationMode()