| 994 | ) |
| 995 | |
| 996 | def test_limit(self): |
| 997 | t = sql.table("t", sql.column("col1"), sql.column("col2")) |
| 998 | |
| 999 | self.assert_compile( |
| 1000 | select(t).limit(10).offset(20), |
| 1001 | "SELECT t.col1, t.col2 FROM t LIMIT %s, %s", |
| 1002 | {"param_1": 20, "param_2": 10}, |
| 1003 | ) |
| 1004 | self.assert_compile( |
| 1005 | select(t).limit(10), |
| 1006 | "SELECT t.col1, t.col2 FROM t LIMIT %s", |
| 1007 | {"param_1": 10}, |
| 1008 | ) |
| 1009 | |
| 1010 | self.assert_compile( |
| 1011 | select(t).offset(10), |
| 1012 | "SELECT t.col1, t.col2 FROM t LIMIT %s, 18446744073709551615", |
| 1013 | {"param_1": 10}, |
| 1014 | ) |
| 1015 | |
| 1016 | @testing.combinations( |
| 1017 | (String,), |