I'm trying to connect to an existing DB on the oracle cloud but every time I try to execute the method that takes care of the connection, the execution returns this error: Process finished with exit code 137 (interrupted by signal 9: SIGKILL)
This is my code:
def connectionDb(tracking_1):
dsn_tns = cx_Oracle.makedsn("xxx.xx.xxx.xxx", "1521", service_name="xxx.xx.xxxxxxxxx.xxxxxx.com") # if needed, place an 'r' before any parameter in order to address special characters such as '\'.
conn = cx_Oracle.connect(user="xxxxxx", password="xxxxxxxxx", dsn=dsn_tns) # if needed, place an 'r' before any parameter in order to address special characters such as '\'. For example, if your user name contains '\', you'll need to place 'r' before the user name: user=r'User Name'
c = conn.cursor()
print("connesso")
# c.execute('''SELECT payload
# FROM SVC_EH.error_instances
# WHERE tracking_var1= {} '''.format(tracking_1)) # use triple quotes if you want to spread your query across multiple lines
c.execute("SELECT payload FROM SVC_EH.error_instances WHERE tracking_var1 = :mybv", mybv=tracking_1)
for row in c:
#return print (row[0], '-', row[1]) # this only shows the first two columns. To add an additional column you'll need to add , '-', row[2], etc.
payload = row[0]
payload = str(payload)
return payload