Problem using Perl DBI-DBD against Oracle

G

GBA

Hi, I'm trying to run this Perl script against a remote Oracle 10g R1
database. I'm using WinXP and i already have the oracle client software
installed and working.

My Perl version is 5.8.7
DBI version is: 1.50
DBD version is: 1.17

#!perl -w

use strict;

use DBI;

my $dbh = DBI->connect( 'dbi:Oracle:maxdev1', 'scott', 'tiger',

{ RaiseError => 1, AutoCommit => 0 } );

print $dbh->selectrow_array(qq{ SELECT 'Hello World' FROM DUAL });

$dbh->disconnect( );

This is the error message i get:

install_driver(Oracle) failed: Can't load
'C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll' for module DBD::Oracle:
load_file:The specified procedure could not be found at
C:/Perl/lib/DynaLoader.pm line 230.
at (eval 3) line 3
Compilation failed in require at (eval 3) line 3.
Perhaps a required shared library or dll isn't installed where expected
at C:\Perl\code\select_dual_short.plx line 9

Any clues about what can be wrong??

Regards
GBA
 
A

A. Sinan Unur

Hi, I'm trying to run this Perl script against a remote Oracle 10g R1
database. I'm using WinXP and i already have the oracle client
software installed and working.
....

This is the error message i get:

install_driver(Oracle) failed: Can't load
'C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll' for module DBD::Oracle:
load_file:The specified procedure could not be found at
C:/Perl/lib/DynaLoader.pm line 230.
at (eval 3) line 3
Compilation failed in require at (eval 3) line 3.
Perhaps a required shared library or dll isn't installed where
expected at C:\Perl\code\select_dual_short.plx line 9

Any clues about what can be wrong??

Exactly what the error message said. I don't know anything about DBD-
Oracle, but the documentation states:

The ORACLE_HOME environment variable should be set correctly. In
general, the value used should match the version of Oracle that was used
to build DBD::Oracle. If using dynamic linking then ORACLE_HOME should
match the version of Oracle that will be used to load in the Oracle
client libraries (via LD_LIBRARY_PATH, ldconfig, or similar on Unix).

ORACLE_HOME can be left unset if you aren't using any of Oracle's
executables, but it is not recommended and error messages may not
display. It should be set to the ORACLE_HOME directory of the version of
Oracle that DBD::Oracle was compiled with.

Check that, check paths, permissions etc.

Sinan

--
A. Sinan Unur <[email protected]>
(remove .invalid and reverse each component for email address)

comp.lang.perl.misc guidelines on the WWW:
http://augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html
 
G

GBA

And how do i find which Oracle was used to build the DBD-Oracle?? I'm
using Perl in Windows XP.

Regards
GBA
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top