-->
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.  [ 5 posts ] 
Author Message
 Post subject: Number of Criteria results
PostPosted: Mon Jul 12, 2004 6:13 am 
Newbie

Joined: Wed Jun 09, 2004 5:53 am
Posts: 6
Is there any way to obtain nuber of objects that particular Criteria would return before calling Criteria.list()?


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 12, 2004 8:58 am 
Senior
Senior

Joined: Fri May 14, 2004 9:37 am
Posts: 122
Location: Cologne, Germany
Calling Criteria.list().size() will return the number of objects inside the list.

regards

Olaf


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jul 12, 2004 9:23 am 
Newbie

Joined: Wed Jun 09, 2004 5:53 am
Posts: 6
BEFORE (!!!) calling Criteria.list()

I have already found a solution
http://opensource.atlassian.com/project ... wse/HB-474


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 13, 2004 7:55 am 
Senior
Senior

Joined: Fri May 14, 2004 9:37 am
Posts: 122
Location: Cologne, Germany
What makes the difference ? Does the count method call a count sql query (so faster ?!).

regards

Olaf


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 13, 2004 8:05 am 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
No, there is no way yet.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 5 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.