MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / _pickle_row_data

Method _pickle_row_data

test/sql/test_resultset.py:434–455  ·  view source on GitHub ↗
(self, connection, use_labels)

Source from the content-addressed store, hash-verified

432 not_in(sql.column("content_type"), row._mapping)
433
434 def _pickle_row_data(self, connection, use_labels):
435 users = self.tables.users
436
437 connection.execute(
438 users.insert(),
439 [
440 {"user_id": 7, "user_name": "jack"},
441 {"user_id": 8, "user_name": "ed"},
442 {"user_id": 9, "user_name": "fred"},
443 ],
444 )
445
446 result = connection.execute(
447 users.select()
448 .order_by(users.c.user_id)
449 .set_label_style(
450 LABEL_STYLE_TABLENAME_PLUS_COL
451 if use_labels
452 else LABEL_STYLE_NONE
453 )
454 ).all()
455 return result
456
457 @testing.variation("use_pickle", [True, False])
458 @testing.variation("use_labels", [True, False])

Callers 2

test_pickled_rowsMethod · 0.95

Calls 6

executeMethod · 0.45
insertMethod · 0.45
allMethod · 0.45
set_label_styleMethod · 0.45
order_byMethod · 0.45
selectMethod · 0.45

Tested by

no test coverage detected