MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_except_style3

Method test_except_style3

test/sql/test_query.py:1289–1301  ·  view source on GitHub ↗
(self, connection)

Source from the content-addressed store, hash-verified

1287 )
1288 @testing.requires.except_
1289 def test_except_style3(self, connection):
1290 # aaa, bbb, ccc - (aaa, bbb, ccc - (ccc)) = ccc
1291 t1, t2, t3 = self.tables("t1", "t2", "t3")
1292
1293 e = except_(
1294 select(t1.c.col3), # aaa, bbb, ccc
1295 except_(
1296 select(t2.c.col3), # aaa, bbb, ccc
1297 select(t3.c.col3).where(t3.c.col3 == "ccc"), # ccc
1298 ),
1299 )
1300 eq_(connection.execute(e).fetchall(), [("ccc",)])
1301 eq_(connection.execute(e.alias("foo").select()).fetchall(), [("ccc",)])
1302
1303 @testing.requires.except_
1304 def test_except_style4(self, connection):

Callers

nothing calls this directly

Calls 8

except_Function · 0.90
selectFunction · 0.90
eq_Function · 0.90
whereMethod · 0.45
fetchallMethod · 0.45
executeMethod · 0.45
selectMethod · 0.45
aliasMethod · 0.45

Tested by

no test coverage detected