Question

In my application that using MSAccess as DB, I need to implement pagewise loading with sql query.

I know how to load first 10 records, thats by

SELECT TOP 10 * FROM Product ORDER BY dateAdded DESC

But how can I pick record that is from 10 to 20.

Any Idea?

Was it helpful?

Solution

It's possible in Access SQL, but not as straightforward as in other database products.
(for example MySQL, where it would be just LIMIT 10,10)

Check out my answer here:
How to do MS Access database paging + search?

(the code to build the SQL Statement is in C#, but of course you can do it in any other language as well. If you don't know C# and need help understanding my answer, just leave a comment here)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top