Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

EJB Lazy Loading etc..

 
Nicky Formosa
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I'm quite new to EJBs, Hibernate etc..

My issue is: I have a DTO which has a few OneToMany and ManyToMany relationships, which i have set them to Load Lazy. Using the EntityManager i want to load the Main DTO. If i try to access a relationship from the main dto i get an error stating that "".

This i could solve using the Join Fetch through HQL but my question is: is there another way of doing things or?

Also what is bothering me is the fact that manytomany relationships access via the Main DTO do not return unique results instead it reaturns a full join!!

Thanks for your time...

Best regards
Nick
 
Nicky Formosa
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
update: the error showing was : "failed to lazily initialize a collection of role...."
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic