LIMIT

LIMIT restricts the number of rows returned by a query. Without ORDER BY, row order is not guaranteed, so the rows returned may vary. It is used to get a preview of the data or to keep only the first results of a ranking. Some engines use TOP or FETCH FIRST instead.

Example

SELECT * FROM commandes LIMIT 10;

Related concepts

The whole glossary