Apply a ``LIMIT`` to the query and return the newly resulting ``Query``. .. seealso:: :meth:`_sql.Select.limit` - v2 equivalent method.
(self, limit: _LimitOffsetType)
| 2648 | @_generative |
| 2649 | @_assertions(_no_statement_condition) |
| 2650 | def limit(self, limit: _LimitOffsetType) -> Self: |
| 2651 | """Apply a ``LIMIT`` to the query and return the newly resulting |
| 2652 | ``Query``. |
| 2653 | |
| 2654 | .. seealso:: |
| 2655 | |
| 2656 | :meth:`_sql.Select.limit` - v2 equivalent method. |
| 2657 | |
| 2658 | """ |
| 2659 | self._limit_clause = sql_util._offset_or_limit_clause(limit) |
| 2660 | return self |
| 2661 | |
| 2662 | @_generative |
| 2663 | @_assertions(_no_statement_condition) |