File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Splitting records in pages

 
vasudevan gopalan
Greenhorn
Posts: 7
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everybody,
In JSP how to split the records so that only a certain number of records can be shown at a time.For eg 10 records in first page and next 10 records in second page and so on.
bye
Vasu
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is a good conversation on paging resultsets in this thread in the JDBC forum.
Dave
 
ramkumar chandramohan
Greenhorn
Posts: 17
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi vasu,
let me know ,What is ur primary key ie int ,string etc,
if int it is easy.
ram
Originally posted by vasudevan gopalan:
Hi everybody,
In JSP how to split the records so that only a certain number of records can be shown at a time.For eg 10 records in first page and next 10 records in second page and so on.
bye
Vasu

 
vasudevan gopalan
Greenhorn
Posts: 7
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hai ram,

i am using string datatype as primary key
bye,
vasu
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After searching the JDBC forum, I really recommend you read these two threads.
Dave.
 
ramkumar chandramohan
Greenhorn
Posts: 17
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi vasu,
Then you need to use Vectors to display all the records.
Originally posted by vasudevan gopalan:
hai ram,

i am using string datatype as primary key
bye,
vasu

 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by ramkumar chandramohan:
hi vasu,
Then you need to use Vectors to display all the records.

ramkumar, I think your answer ignores all the possible complications. Ignoring the fact the Vector isn't too efficient, if we store it in an object (of some sort) then we have to hold onto this object, which can take up significant resources, the data that produced the results can change in the background and the "object" won't refect that change, and if you are talking hundreds to thousands of rows with a whole lot of large attributes can add up to megs of data per person...
Just think the solution has to be discussed in context rather than offering a broad solution.

Dave.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic