Recognizing cx_Oracle install within PyDev
You can try this (after the steps that you already report in your question)
Check if the installation in PyDev is ok (besides showing an error marker for
import cx_Oracle
)import cx_Oracleconn = cx_Oracle.connect('hr/hr@pdborcl')cur = conn.cursor()cur.execute('select 13 from dual')for r in cur.fetchall(): print(r)
If this works, and prints
(13,)
the installation is correct. Likely some part of completion could work as well. In addition, Shift+Click oncx_Oracle
should reportThe definition of ... was found at ...
.Go to Windows > Preferences > PyDev > Interpreters > Python Interpreter and on the tab Forced builtins add
cx_Oracle
After rebuilding the project, the error markers on the import should go away. (In the little test program I just did a trivial edit and saved.)
For the record:
Eclipse Version: 4.6.0 (Neon)PyDev Version: 5.2.0Python: 3.5.2 (from a virtualenv)