$limit controls the maximum number of rows that will be returned.
$offset controls which row that will be the first in the result
set from the total amount of matching rows.
Example:
$q->select( '*' )->from( 'table' )
->limit( 10, 0 );
LIMIT is not part of SQL92. It is implemented here anyway since all
databases support it one way or the other and because it is
essential. /** * Loads field data for given $pass. * * @param \eZ\Publish\Core\Persistence\Database\SelectQuery $query * @param int $bulkCount * @param int $pass * * @return array */ protected function loadData(SelectQuery $query, $bulkCount, $pass) { $query->limit($bulkCount, $pass * $bulkCount); $stmt = $query->prepare(); $stmt->execute(); return $stmt->fetchAll(PDO::FETCH_ASSOC); }