Hello Sudarson, one of possible ways( at least I am using it) is using a searcher class, which will implement the search over your databases or indexes and store all hits(search results) in an instance of, say Hits, class allowing you iterate through them. You can cache it to avoid redundant search process if you want to see "next N results" and just ask your cached Hits object for next N hits, following from the last displayed.
Maxim -- Original message -- From: "Sudarson Roy Pratihar" <[EMAIL PROTECTED]> Date: Monday, February 04, 2002, 1:09:02 PM Subject: How Pagination can be handled optimally ? SRP> Hi All, SRP> The pagination is very common feature of any web application. When we SRP> have search screen or summary screen, we can have a lots of search SRP> result and we may want to show the result page wise. Now how this can be SRP> done optimally ? B'coz say in search we get 1000 records and we want to SRP> show the result sorted alphabetically and 10 per page. Now what are the SRP> ways we can achieve that and which one is the optimal solution ? SRP> Any suggestion is welcome. SRP> TIA, SRP> Sudarson SRP> ___________________________________________________________________________ SRP> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body SRP> of the message "signoff SERVLET-INTEREST". SRP> Archives: http://archives.java.sun.com/archives/servlet-interest.html SRP> Resources: http://java.sun.com/products/servlet/external-resources.html SRP> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
