wood burning stoves 2.0*
The moose likes JDBC and the fly likes Pagination Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Pagination " Watch "Pagination " New topic
Author

Pagination

Ingudam Manoranjan
Ranch Hand

Joined: Jul 31, 2006
Posts: 48
I have been looking around for implementing pagination. Most of the literature point out to getting the whole records from the Database into the memory and display pagination. However I am looking at 2 level pagination, one at UI level and other at getting fix set of records from Database.

For example, I might want to show to the user only 10 records per page but would like to retrieve say about 100 records only from the database, even if the select query matches more that , say, 300 records. Getting all the 300 records at one go will be costly. So I was thinking of having another level of pagination where a parameter will specify how many records to be retrieved from the database.

I would be grateful for any help or pointers for best practices surrounding such requirement.

Thanks,
Ingudam Manoranjan
Remko Strating
Ranch Hand

Joined: Dec 28, 2006
Posts: 893
This link could help you, which is a summarization of discusions in the past


PaginationOrPaging


Remko (My website)
SCJP 1.5, SCWCD 1.4, SCDJWS 1.4, SCBCD 1.5, ITIL(Manager), Prince2(Practitioner), Reading/ gaining experience for SCEA,
Ingudam Manoranjan
Ranch Hand

Joined: Jul 31, 2006
Posts: 48
Thanks Remko. Something like this is exactly what I had been looking for.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Pagination