Duplicate of Limiting query in MS Access in PHP
I know the query of mysql in php with both limit and page number.
$result = mysql_query("SELECT * FROM tname WHERE year='$y' ORDER BY date DESC LIMIT $pg, $limit");
Here $pg is page number and $limit is the number of records per page.
Now i want to run the same query with MS Access Database with Java Platform.
I found that the keyword limit
cannot be used in ms access, so found Top
keyword.
So my final working query is
ResultSet rs=sta.executeQuery("SELECT top 100 * FROM tname WHERE year='$y' ORDER BY date DESC");
I want to include the page number in the ms access query... How can i do this ??? My database table has approx 3000 rows.
I want a query like the above mysql query with page number and limit which works in ms access.
Thanks in advance.