File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change 7474 result = cursor .fetchone ()
7575 print (f" Special Chars Query Result: { result [0 ]} " )
7676
77+ # Query 4: No tags (demonstrates tags don't persist from previous queries)
78+ cursor .execute ("SELECT 4" )
79+ result = cursor .fetchone ()
80+ print (f" No Tags Query Result: { result [0 ]} " )
81+
7782print ()
7883
7984# Example 3: Async execution with query tags
8691
8792 with connection .cursor () as cursor :
8893 cursor .execute_async (
89- "SELECT 4 " ,
94+ "SELECT 5 " ,
9095 query_tags = {"team" : "data-eng" , "mode" : "async" }
9196 )
9297 cursor .get_async_execution_result ()
107112 # Execute multiple queries with the same tags
108113 cursor .executemany (
109114 "SELECT ?" ,
110- [[5 ], [6 ], [7 ]],
115+ [[6 ], [7 ], [8 ]],
111116 query_tags = {"team" : "data-eng" , "batch" : "executemany" }
112117 )
113118 result = cursor .fetchone ()
You can’t perform that action at this time.
0 commit comments