Anthony,

I encountered the exact same problem as you described when I upgraded my
perl installation from 5.004_04 to 5.6.1 quite a while ago.  Scripts that
used both DB_File to access berkeley DB files, and DBI to access oracle
caused the DB files to become corrupted whenever they were modified.  The
DB files could be read without any problems, but the first modification
caused the files to become corrupted.

I tried a few different versions of DBI, up to about 1.18, but the problem
remained.  Since I left my 5.004_04 installation around after the perl
upgrade, my solution was to run all scripts that needed both DBI and
DB_File to use 5.004_04 instead of 5.6.1.  This band-aid fix has
worked for several months, but I would like to find a more permanent fix.  

I've thought recently of replacing DB_File with the BerkeleyDB module, to
see if that fixes the corruption problem.  However, I've not yet tried
that approach.  

chris

On Thu, 27 Dec 2001, Anthony Guselnikov wrote:

> Hi,
> 
>   I'm trying to create Berkeley DB binary files using some information
>   from my Oracle database. I'm using DB_File.pm(perl 5.6.1 dist),
>   B-trees for handling Berkeley DB and DBI (DBD::Oracle) version 1.14.
>   
>   For some bizarre reason when connect method of the DBI package is
>   called all my tied hashes in Berkeley DB module get messed up.
> 
>   i.e. suppose a %tied_hash that is tied to Berkeley DB file
>   xxx.db.
> 
>   as soon as I do
>   my $dbh = DBI->connect('dbi:Oracle:host=myhost;sid=SID','username','password');
>   xxx.db gets corrupted.
> 
>   Did anyone ever experience anything like that? Any help would be
>   greatly appreciated.
> 

Reply via email to