PostgreSQL supports windowing functions as defined by the SQL standard, but they're awkward, so most people use (the non-standard) LIMIT
/ OFFSET
:
SELECT *FROM mytableORDER BY somefieldLIMIT 1 OFFSET 20;
This example selects the 21st row. OFFSET 20
is telling Postgres to skip the first 20 records. If you don't specify an ORDER BY
clause, there's no guarantee which record you will get back, which is rarely useful.