Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Take

Picks rows based on their position.

take (n|range)

See Ranges for more details on how ranges work.

Examples

PRQL

from employees
take 10

SQL

SELECT
  *
FROM
  employees
LIMIT
  10

PRQL

from orders
sort {-value, created_at}
take 101..110

SQL

SELECT
  *
FROM
  orders
ORDER BY
  value DESC,
  created_at
LIMIT
  10 OFFSET 100