MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / test_except_style4

Method test_except_style4

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

Source from the content-addressed store, hash-verified

1302
1303 @testing.requires.except_
1304 def test_except_style4(self, connection):
1305 # aaa, bbb, ccc - (aaa, bbb, ccc - (ccc)) = ccc
1306 t1, t2, t3 = self.tables("t1", "t2", "t3")
1307
1308 e = except_(
1309 select(t1.c.col3), # aaa, bbb, ccc
1310 except_(
1311 select(t2.c.col3), # aaa, bbb, ccc
1312 select(t3.c.col3).where(t3.c.col3 == "ccc"), # ccc
1313 )
1314 .alias()
1315 .select(),
1316 )
1317
1318 eq_(connection.execute(e).fetchall(), [("ccc",)])
1319 eq_(connection.execute(e.alias().select()).fetchall(), [("ccc",)])
1320
1321 @testing.requires.intersect
1322 @testing.fails_on(

Callers

nothing calls this directly

Calls 8

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

Tested by

no test coverage detected