-->
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.  [ 4 posts ] 
Author Message
 Post subject: Setting Max Fetch Depth for One Query?
PostPosted: Mon Apr 04, 2005 7:41 pm 
Regular
Regular

Joined: Sun Sep 26, 2004 9:27 pm
Posts: 75
Location: Atlanta, GA, USA
Is it possible to set the Environment max_fetch_depth property for a particular query?

In other words, my default configuration has a depth of 2. However, in one case I would like a depth of 3. Generically, I'd like the depth to remain 2 for all other queries, but different for this one.

Thanks for any help.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 05, 2005 1:32 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
HQL queries are not influenced by max fetch depth

_________________
Emmanuel


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 05, 2005 1:42 pm 
Regular
Regular

Joined: Sun Sep 26, 2004 9:27 pm
Posts: 75
Location: Atlanta, GA, USA
If not HQL, what does it affect?

What is the purpose of the Query.setFetchSize()? The API states:

Quote:
Set a fetch size for the underlying JDBC query.


Which is a tad confusing to me. What does it do?


Top
 Profile  
 
 Post subject:
PostPosted: Tue Apr 05, 2005 1:50 pm 
Hibernate Team
Hibernate Team

Joined: Sun Sep 14, 2003 3:54 am
Posts: 7256
Location: Paris, France
fetchSize Gives the JDBC driver a hint as to the number of rows that should be fetched from the database when more rows are needed

fetch depth : number of joins used to retrieved the object graph

_________________
Emmanuel


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

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.