Thomas SMETS
Posts: 307
Nickname: tsmets
Registered: Apr, 2002
|
|
Re: Problem with Paging
|
Posted: Apr 8, 2002 4:09 AM
|
|
There is on every DataBase the noton of a Cursor. Just learn what they mean & try to use the syntax accordingly.
On postgreSQL you can have the following syntax : SELECT customer_id from CUSTOMER ORDER BY customer_id LIMIT 3;
or, say you want the 5th to the 10th : SELECT customer_id from CUSTOMER ORDER BY customer_id LIMIT 5 OFFSET 5;
The notion of CURSOR is present on any relevant DB (Oracle, Sybase, Informix, SQLserver, ...). JDBC 2 allows you to include the ResultSet browsing in the Java code, too !
Thomas, tsmets @ lautre . net
|
|