Problem with that second solution is that it leads to the N+1 problem. There is a third solution - use LEFT JOIN FETCH.
If you have a collection that is configure for lazy loading, you can execute a JPQL query that left join fetches the collection you want to eagerly load. There is plenty of info on the net about left join fetches if you want to learn more. All of these solutions mentioned in this thread are not hibernate specific. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4055198#4055198 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4055198 _______________________________________________ jboss-user mailing list [email protected] https://lists.jboss.org/mailman/listinfo/jboss-user
