dba has asked for the wisdom of the Perl Monks concerning the following question:
I loop through a list of databases to query. When I mix $dbh = DBI->connect($tns,$uid,$pswd,{ ora_session_mode =>2}) with DBI->connect($tns,$uid,$pswd), (based on the database) perl crashes at the end of the program. However, if I use only one way to connect, it exits normally. Any one used this, or have any suggestions to fix this error ?
Re: Help on DBI/DBD Oracle needed.
by Anneq (Vicar) on Apr 23, 2004 at 20:46 UTC
|
Do you get any errors? Perhaps if you add:
or die $DBI::errstr;
to the end or your connect statements, that might give you some idea what is going on.
Good luck,
Anne
| [reply] [d/l] |
|
Thanks for the reply. I do it in every connect. However, connect /query runs fine. I have also a print statement as the last line of the code, which executes just fine. But when perl exits, it crashes.
| [reply] |
|