Forum Stats

  • 3,769,586 Users
  • 2,252,984 Discussions
  • 7,875,105 Comments

Discussions

cx_oracle ImportError: No module named 'cx_oracle'

va*447258*15
va*447258*15 Member Posts: 298
edited Dec 1, 2014 4:28PM in Python

Hi,

Please anyone can help me in regard to fix this issue as when trying to import cx_oracle getting error (ImportError: No module named 'cx_oracle')

I have installed oracle 11g express edition (64 bits)

pythong3.3 (64)

D:\instantclient_11_2 (64)

cx_oracle is installed at c:\python3.3 folder for windows64 bit

windows7 64bits

oracle express11g 64 bits

oracle home environment variable is adjusted to D:\instantclient_11_2

path = c:\python3.3

Please anyone can guide me have i made any error during installation or do i have to follow any steps.

Best Regards,

Van

Christopher Jones-OracleLars Sjöström

Answers

  • Christopher Jones-Oracle
    Christopher Jones-Oracle Member Posts: 1,643 Employee

    Did you set PATH to the Instant Client directory and reboot?

  • 008db739-46eb-40af-9dbc-785541071301
    edited Dec 1, 2014 4:28PM

    Cannot help with Windows related installation issues, but did you try uppercase 'O' in cx_Oracle.

    [wrong - lowercase 'o']

    In [7]: import cx_oracle

    ---------------------------------------------------------------------------

    ImportError                               Traceback (most recent call last)

    <ipython-input-7-fa7af752f8a0> in <module>()

    ----> 1 import cx_oracle

    ImportError: No module named cx_oracle

    [correct - uppercase 'O']

    In [1]: import cx_Oracle

    In [8]: dir(cx_Oracle)

    Out[8]:

    ['ATTR_PURITY_DEFAULT',

    'ATTR_PURITY_NEW',

    'ATTR_PURITY_SELF',

    'BFILE',

    'BINARY',

    ...

    Christopher Jones-OracleLars Sjöström
This discussion has been closed.