You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-mysqlclient/src/opentelemetry/instrumentation/mysqlclient/__init__.py
+2
Original file line number
Diff line number
Diff line change
@@ -51,6 +51,7 @@
51
51
52
52
cnx = MySQLdb.connect(database="MySQL_Database")
53
53
cursor = cnx.cursor()
54
+
cursor.execute("CREATE TABLE IF NOT EXISTS test (testField INTEGER)")
54
55
cursor.execute("INSERT INTO test (testField) VALUES (123)"
55
56
cnx.commit()
56
57
cursor.close()
@@ -73,6 +74,7 @@
73
74
}
74
75
)
75
76
cursor = instrumented_cnx.cursor()
77
+
cursor.execute("CREATE TABLE IF NOT EXISTS test (testField INTEGER)")
76
78
cursor.execute("INSERT INTO test (testField) VALUES (123)"
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-psycopg/src/opentelemetry/instrumentation/psycopg/__init__.py
+2
Original file line number
Diff line number
Diff line change
@@ -94,6 +94,7 @@
94
94
cnx = psycopg.connect(database='Database')
95
95
96
96
cursor = cnx.cursor()
97
+
cursor.execute("CREATE TABLE IF NOT EXISTS test (testField INTEGER)")
97
98
cursor.execute("INSERT INTO test (testField) VALUES (123)")
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-psycopg2/src/opentelemetry/instrumentation/psycopg2/__init__.py
+2
Original file line number
Diff line number
Diff line change
@@ -94,6 +94,7 @@
94
94
cnx = psycopg2.connect(database='Database')
95
95
96
96
cursor = cnx.cursor()
97
+
cursor.execute("CREATE TABLE IF NOT EXISTS test (testField INTEGER)")
97
98
cursor.execute("INSERT INTO test (testField) VALUES (123)")
Copy file name to clipboardExpand all lines: instrumentation/opentelemetry-instrumentation-sqlite3/src/opentelemetry/instrumentation/sqlite3/__init__.py
+2-2
Original file line number
Diff line number
Diff line change
@@ -32,7 +32,7 @@
32
32
33
33
cnx = sqlite3.connect(':memory:')
34
34
cursor = cnx.cursor()
35
-
cursor.execute("CREATE TABLE test (testField INTEGER)")
35
+
cursor.execute("CREATE TABLE IF NOT EXISTS test (testField INTEGER)")
36
36
cursor.execute("INSERT INTO test (testField) VALUES (123)")
0 commit comments