-->
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: left join (fetch) + setMaxResults
PostPosted: Mon Feb 26, 2007 10:50 am 
Newbie

Joined: Fri Apr 22, 2005 3:39 pm
Posts: 18
Hi!

A question to Hibernate gurus: what query strategy does latest hibernate use to implement max.results (SQL limit) with left join (fetch)? What are workarounds?

"Hibernate in Action" says this is illegal, as max.results (SQL limit) will render the query inconsistent but notes that hibernate may fall silently to "workaround" strategies.

Example:
(from Cat c left join fetch c.kittens).setMaxResult(N);
I want all kittens correctly fetched eagerly and want only N cats.


Thanks!!!


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.