Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Issue with Connection Oracle 11.2 database from Perl.

778223Nov 9 2010 — edited Nov 9 2010
Hello,

We are trying to connect oracle 11.2 database from a perl script. I have verified that DBD::ORACLE version is 1.19. The environment is linux environment. Linux is SuSE linux and version is 10 SP1.

The code we are executing is

============
#!/usr/bin/perl -w
use strict;
use DBI;
my $db = DBI->connect( "dbi:Oracle:SID", "USERID", "XXXXXX" )
|| die( $DBI::errstr . "\n" );
my $SEL = "SELECT sysdate FROM DUAL";
my $sth = $db->prepare($SEL);
$sth->execute();

my($cdate);

while ( $sth->fetch() ) {
Print "DATE: $cdate\n";
}

$sth->finish() ;
=======================


We are receiving following error:
install_driver(oracle) failed: Can't locate DBD/oracle.pm in @INC (@INC contains
b/perl5/site_perl/5.8.8/x86_64-linux-thread-multi /usr/lib/perl5/site_perl/5.8.8
d-multi /usr/lib/perl5/vendor_perl/5.8.8 /usr/lib/perl5/vendor_perl .) at (eval
Perhaps the DBD::oracle perl module hasn't been fully installed,
or perhaps the capitalisation of 'oracle' isn't right.
Available drivers: DBM, ExampleP, File, Oracle, Proxy, Sponge, mysql.
at ./conn_db.pl line 4


Please let us knowhow to resolve the issue?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 7 2010
Added on Nov 9 2010
3 comments
2,438 views