MCPcopy Index your code
hub / github.com/geldata/gel / test_sql_dml_insert_09

Method test_sql_dml_insert_09

tests/test_sql_dml.py:245–256  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

243 )
244
245 async def test_sql_dml_insert_09(self):
246 # insert with a CTE
247 await self.scon.execute(
248 '''
249 WITH a AS (
250 SELECT 'Report' as t UNION ALL SELECT 'Briefing'
251 )
252 INSERT INTO "Document" (title) SELECT * FROM a
253 '''
254 )
255 res = await self.squery_values('SELECT title FROM "Document"')
256 self.assertEqual(res, tb.bag([['Report (new)'], ['Briefing (new)']]))
257
258 async def test_sql_dml_insert_10(self):
259 # two inserts

Callers

nothing calls this directly

Calls 2

executeMethod · 0.80
squery_valuesMethod · 0.80

Tested by

no test coverage detected