470,591 Members | 2,005 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 470,591 developers. It's quick & easy.

Connecting Oracle8i to Python

Hello,
I'm a newbie to Python. In order to get much use out of it at my
site, I must be able to connect it to Oracle8i databases. I'm running
Python 2.2.2 on Tru64 (osf1 V5.1a).

First question:
What do you recommend?
DCOracle2? Note that I am not running Zope or any other web software.
cx_Oracle?
Other?

Second question (important only if you recommend DCOracle2)
I can "make" DCOracle2, but I don't see any hints anywhere on how to
install it on a non-zope system. If I try any obvious thing, like cp
-r to lib/python2.2/site-packages, at BEST I get:
python Python 2.2.2 (#1, May 9 2003, 14:15:51) [C] on osf1V5
Type "help", "copyright", "credits" or "license" for more information.
import DCOracle2

Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "DCOracle2/__init__.py", line 37, in ?
from DCOracle2 import *
File "DCOracle2/DCOracle2.py", line 104, in ?
import dco2
ImportError: dlopen: DCOracle2/dco2.so: symbol "OCILobIsTemporary"
unresolved

What is going on here?
I think that OCILobIsTemporary is supposed to be in the Oracle8i
client shared library, so maybe that library isn't getting loaded.
What am I doing wrong? I've tried playing with
LD_LIBRARY_PATH=$ORACLE_HOME/lib but nothing seems to work. I've even
forced src/Makefile to include -rpath $ORACLE_HOME/lib .

I should point out that I have other non-python apps that can use the
oracle client library just fine, and nm libclntsh.so | grep OCILobIsTemporary

OCILobIsTemporary | 0004396966856416 | T |
0000000000000008

Doug
Jul 18 '05 #1
1 2947
do************@tnzi.com (the_rev_dharma_roadkill) wrote in message news:<fb*************************@posting.google.c om>...
Hello,
I'm a newbie to Python. In order to get much use out of it at my
site, I must be able to connect it to Oracle8i databases. I'm running
Python 2.2.2 on Tru64 (osf1 V5.1a).

First question:
What do you recommend?
DCOracle2? Note that I am not running Zope or any other web software.
cx_Oracle?
Other?

Second question (important only if you recommend DCOracle2)
I can "make" DCOracle2, but I don't see any hints anywhere on how to
install it on a non-zope system. If I try any obvious thing, like cp
-r to lib/python2.2/site-packages, at BEST I get:
python

Python 2.2.2 (#1, May 9 2003, 14:15:51) [C] on osf1V5
Type "help", "copyright", "credits" or "license" for more information.
import DCOracle2 Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "DCOracle2/__init__.py", line 37, in ?
from DCOracle2 import *
File "DCOracle2/DCOracle2.py", line 104, in ?
import dco2
ImportError: dlopen: DCOracle2/dco2.so: symbol "OCILobIsTemporary"
unresolved


I actually can get past this now using libocijdbc8 but now I get:
import DCOracle2

Traceback (most recent call last):
File "<stdin>", line 1, in ?
File "DCOracle2/__init__.py", line 91, in ?
import DA
File "DCOracle2/DA.py", line 90, in ?
from db import DB
File "DCOracle2/db.py", line 89, in ?
import DCOracle2, DateTime
ImportError: No module named DateTime
How many other non-standard modules do I need to install to get
DCOracle2 working in a non-zope vanilla environment?
Jul 18 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

reply views Thread by christian_stengel | last post: by
1 post views Thread by Stephane VUILLIN | last post: by
1 post views Thread by yahibble | last post: by
1 post views Thread by John | last post: by
2 posts views Thread by python_eager | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.