Installation problems DCOracle2 & W2000

brueckd at tbye.com brueckd at tbye.com
Wed Jun 26 15:18:21 EDT 2002


On Wed, 26 Jun 2002, Talon wrote:

> OK, here you go:
> 
> Path = C:\Python21\;  (I don't have a specific PYTHONPATH variable set. 
> This is in the general PATH variable)
> 
> The error I get is
> 
> File "C:\Python21\myfiles\htsa_data_loader_v2.py", line 9, in ?
>   import os,sys,re,string,DCOracle2
> File "C:\Python21\DCOracle2\__init__.py", line 91, in ?
>   import DA
> File "C:\Python21\DCOracle2\DA.py", line 90, in ?
>   from db import DB
> File "C:\Python21\DCOracle2\db.py", line 89, in ?
>   import DCOracle2, DateTime
> ImportError: No module named DateTime
> 
> DateTime is located in C:\Program Files\ZopeDev\lib\python\DateTime

Aha! Here's what I think the problem is: the DCOracle2 bundle off the Zope 
site comes all wrapped up in the Zope database adapter (ZOracleDA), so 
your above script is actually trying to import the DA and not the 
DCOracle2 package itself (I can see why this is confusing - both 
directories are named DCOracle2 but one is a subdirectory of the other!).

So... if you look in c:\python21\DCOracle2 you should find a subdirectory 
in there also called DCOracle2. This is the only one you should need for 
doing standalone (none-Zope) work with Oracle. The easiest thing to do is 
rename c:\python21\DCOracle2 to DCOracle2bak or something, and then move 
its DCOracle2 subdirectory into c:\python21 and then try your script 
again. 

Does this make sense? Please let me know if it doesn't or if it still 
doesn't work after that.

-Dave






More information about the Python-list mailing list