Answer the question
In order to leave comments, you need to log in
If there are other options to connect to Oracle other than cx_Oracle?
Hello.
at the moment I use the
cx_Oracle library to connect to oracle
#!/usr/bin/python
import cx_Oracle
ip = 'hostname'
port = 1522
SID = 'oraclesid'
dsn_tns = cx_Oracle.makedsn(ip, port, SID)
print (dsn_tns)
conn = cx_Oracle.connect('user', 'password', dsn_tns)
c = conn.cursor()
c.execute(sql_script)
for row in c:
print (row[0], row[1])
conn.close()
Traceback (most recent call last):
File "oracle.py", line 2, in <module>
import cx_Oracle
ImportError: DLL load failed: %1 is not a valid Win32 application.
Answer the question
In order to leave comments, you need to log in
So there is nothing wrong with installing a client on a server. Once set and forgotten.
In principle, you can work with Oracle through ODBC and JDBC (as in SQL Developer, for example), in python this is the JayDeBiApi module. Try it, I haven't personally tried it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question