I have seen some site use something like this in their URLs:


This in turn would return the first 20 records from a database. Then there would be a link that would have the following URL:


This would return the next 20 records.

How do you actually inplement this? What is the correct query to do something like this?