On Tue 06 Dec 2011 09:00:00 AM CST, David Mansfield wrote:
I guess if you use session.load instead of session.get you won't
get
10,000 queries over the network if batch fetching is enabled, which
does exactly what the original issue discusses, it splits the "in"
clause into chunks and executes it in an intelligent manner. It's a
shame the same can't be worked into a solution when a criteria or hql
query is used - to me this is more a breakage in SQL than in hibernate.
If you use session.get your performance will be absolutely horrendous
compared to an "in" or global temp table (I state this mainly for the
record, not because it's some new information to you ;-)
Great! Then use load(). next... ;)
There is a huge difference here wrt the query splitting... We know for
certain the structure of the query and the fact that we do not have to
worry about AND/OR predicate branches and how splitting might effect the
overall semantic of the query.
Guys, if there is something more you would like to say, why not say it
on the issue? That way we are not having to repeat this same
information between the 2 places...
--
steve(a)hibernate.org
http://hibernate.org