• Post Reply Bookmark Topic Watch Topic
  • New Topic

Retriving data from data base

 
Pankaj Patro
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Every Body,

This is the scenario where I am going to work:-
SCENARIO:- In the database there is more than 100000 records are there,
but I need to display only 100 records on the screen, when my user interface press the next button, then next 100 will pop-up and displays. But we are not suppose to write any queries in the tablename.hbm.xml file.


Can any one suggest me how to achive this.
[ April 10, 2006: Message edited by: Aryan Jones ]
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You could use Criteria. It has setFetchSize() and setFirstResults() methods.
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!