Hello,
When I run a script from shell using DBI and I have LIBPATH set to something other than when DBI was compiled, I get a install_driver(oracle) error and the script dies.
$dbh = DBI->connect(dbi:Oracle:etc.....)
unsetting LIBPATH always works. The problem is I want to trap this error so the script doesn't die if someone executes it with the wrong LIBPATH. The only way I have found to do this is the expensive operation of calling
my @drivers = DBI->installed_versions;
and then check to see if Oracle is there before I DBI->connect.
Additionally, since the linkers cache the LIBPATH value before the script even executes (from what i understand), i can't unsetLIBPATH in a BEGIN block either.
Does anyone have a suggestion as to how I can deal with this other than using DBI->installed_versions ?
Editted by BazB: fixed formatting/code tags. In reply to DBI problems.
by dbaad
For:
Use:
& & < < > > [ [ ] ]