Pool connection closes if connection/cursor object is used AFTER RETURNING it from a function? #159
Replies: 1 comment 3 replies
-
My initial thoughts are that the pool has been closed since it has gone out of scope. You need to leave it in scope for it to remain open! It is highly likely that cx_Oracle.SessionPool internally retained a reference to the pool on the connection that was acquired from the pool -- which prevented it from closing completely -- an internal implementation detail! |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
What am I missing?
The following scheme WORKS in python-oracledb:
But, the following scheme DOES NOT WORK in python-oracledb because it causes these errors:
DPY-4011: the database or network closed the connection
DPI-1010: not connected
Note that the 2nd scheme worked for me when using cx_Oracle.SessionPool(), but it doesn't with python-oracledb...
In case it's relevant, my sqlnet.ora file looks like this:
Thoughts?
Justin
Beta Was this translation helpful? Give feedback.
All reactions