-->
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: Iterating criteria results & Cache
PostPosted: Thu Mar 17, 2005 11:52 am 
Regular
Regular

Joined: Mon Feb 23, 2004 10:42 pm
Posts: 102
Location: Washington DC
Read the rules before posting!
http://www.hibernate.org/ForumMailingli ... AskForHelp

Hibernate version:
3.0rc1

I have noticed that the only way to get results back from a query using the Criteria is to do a list(). We are trying to get some an improvement in performance of our queries and hence looking at the 2nd level cahce. In our application, since all inserts are being done through hibernate, these will be inserted into the 2nd level cache. The only reason why I am using the criteria api is to build up queries programmatically.

Is there a way that I can take advantage of the 2nd level cache using criteria in the same way that Query.iterate() does?

_________________
Matt Veitas


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 17, 2005 12:13 pm 
Regular
Regular

Joined: Mon Feb 23, 2004 10:42 pm
Posts: 102
Location: Washington DC
Is there any way to get the HQL string from the criteria object?

_________________
Matt Veitas


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 17, 2005 12:41 pm 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
No, not possible


Top
 Profile  
 
 Post subject:
PostPosted: Thu Mar 17, 2005 1:17 pm 
Regular
Regular

Joined: Mon Feb 23, 2004 10:42 pm
Posts: 102
Location: Washington DC
Is there any technical issues as to why criteria does not allow iterate?

_________________
Matt Veitas


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.