Given a result set or collection can anyone help in implementing a next page previous page functionality. Should be able to list a set amount of records that will be viewed and if you get real fancy indicate how many pages are present basically the same as this site uses
As previously stated you can one of two things. First off the easiest would be to simply supply the offset option in your sql code and create a new Collection each time the page is loaded and pass that to the view. Or you can create a Collection and cache it to memory and only pull the specified number of objects from the Collection. If you need examples let me know.
Some database does not support the LIMIT statement. How to tackle this? I come to know that db2 is one of db that does not support this. The closest thing to a LIMIT function is FETCH is db2. Maybe using FETCH with ORDER and WHERE will produce the results but i dont think its feasible.
Using caching I think will also eat up memory especially if the resultset is large in the region of thousands. So have to fully load up the thousands of records in to memory before finally displaying the first page.
Using cache rowset is also another way but i found out some webserver does not support this method such as Websphere.
So I was wondering is there a universal way to do this that can run on any webserver and database and on the same time does not take too much of a time to process.
SCJP, SCWCD, SCBCD, IBM CSD WebSphere v5, <br />A+, MCP 2000 and 2000 server, CST, and few incompleted certification tracks.<br /> <br />Ivory Coast<br /> <br />Analyze your web Request/Response @ <a href="http://webtools.servehttp.com" target="_blank" rel="nofollow">http://webtools.servehttp.com</a> down for a while...