struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Licco <hkustli...@gmail.com>
Subject Pagination Questions
Date Sat, 29 Nov 2008 08:08:23 GMT
Dear All,
I am currently working on pagination to the result of search result. I  
want to ask which solution is better?
1. After user chooses some criterias and then clicks the search  
button, the server will return the size of search result and the  
objects of first page of the search result. Then when user clicks the  
different page number, the server will get the data for that page from  
DB. But for this solution, it requires DB access when you click the  
page number.

2.After user clicks the search button, the server will get all the  
objects(like all the films which the user wanna.). Then when user  
clicks different page number, the server will just return the data  
from memory. This seems to reduce the DB access times.

3. Use some preload method to store the data for the next few pages in  
a buffer.

Which solution will achieve a fast search and reduce the access load  
to the DB?

Thanks a lot for your feedback!

Li, Ke (Licco)

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message