MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_result_map_limit

Method test_result_map_limit

test/sql/test_labels.py:279–291  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

277 self._assert_labeled_table1_select(s)
278
279 def test_result_map_limit(self):
280 table1 = self.table1
281 # some dialects such as oracle (and possibly ms-sql in a future
282 # version) generate a subquery for limits/offsets. ensure that the
283 # generated result map corresponds to the selected table, not the
284 # select query
285 s = (
286 table1.select()
287 .set_label_style(LABEL_STYLE_TABLENAME_PLUS_COL)
288 .order_by(table1.c.this_is_the_primarykey_column)
289 .limit(2)
290 )
291 self._assert_labeled_table1_select(s)
292
293 def test_result_map_subquery(self):
294 table1 = self.table1

Callers

nothing calls this directly

Calls 5

limitMethod · 0.45
order_byMethod · 0.45
set_label_styleMethod · 0.45
selectMethod · 0.45

Tested by

no test coverage detected