MCPcopy Create free account
hub / github.com/psf/black / limit_offset_sql

Function limit_offset_sql

tests/data/conditional_expression.py:47–57  ·  view source on GitHub ↗

Return LIMIT/OFFSET SQL clause.

(self, low_mark, high_mark)

Source from the content-addressed store, hash-verified

45
46
47def limit_offset_sql(self, low_mark, high_mark):
48 """Return LIMIT/OFFSET SQL clause."""
49 limit, offset = self._get_limit_offset_params(low_mark, high_mark)
50 return " ".join(
51 sql
52 for sql in (
53 "LIMIT %d" % limit if limit else None,
54 ("OFFSET %d" % offset) if offset else None,
55 )
56 if sql
57 )
58
59
60def something():

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected