williey
Technical User
- Jan 21, 2004
- 242
I received the following error when trying to perform a simple DB connect and disconnect to Oracle. Has anyone encounter similar problems? This is on a Win 2000 platform.
Reinstalling DBI package does not help.
DBD::ORACLE initialisation failed; can't locate object method "driver" via package DBD::ORACLE"
Reinstalling DBI package does not help.
DBD::ORACLE initialisation failed; can't locate object method "driver" via package DBD::ORACLE"
Code:
#!/usr/bin/perl
# db_test.pl
use strict;
use DBI;
use lib;
### Perform the connection using the Oracle driver
my $dbh = DBI->connect( "DBI:Oracle:dev01", "xxx", "xxx" )
or die "Can't connect to Oracle database: $DBI::errstr\n";
### Now, disconnect from the database
$dbh->disconnect
or warn "Disconnection failed: $DBI::errstr\n";
exit;