| Store | Cart

RE: Perl-Oracel-error

From: Waghmare, Satish (IE03x) <Sati...@honeywell.com>
Thu, 27 Jan 2005 11:32:03 +0530
Hi Friends:

I have set ORACLE_HOME and all required PATH environment variables set.

But Still I'm not able to connect to Oracle Database, 
When I ran my Perl script from DOS prompt 
C:\PERL o.pl 
It prompts me a Messagebox with error : 
"The ordinal 435 could not be located in the dynamic link library
CORE40.dll"

When I clicked OK on the msgbox, it prints error in DOS window as below:
C:\>perl o.pl
install_driver(Oracle) failed: Can't load
'C:/Perl/site/lib/auto/DBD/Oracle/Orac
le.dll' for module DBD::Oracle: load_file:The operating system cannot run %1
at
C:/Perl/lib/DynaLoader.pm line 229.
 at (eval 1) line 3
Compilation failed in require at (eval 1) line 3.
Perhaps a required shared library or dll isn't installed where expected
 at o.pl line 12

C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll 
C:/Perl/lib/DynaLoader.pm                       These files are present on
my system.

Below is the code on Line 229 in DynaLoader.pm: 
    my $libref = dl_load_file($file, $module->dl_load_flags) or
	croak("Can't load '$file' for module $module: ".dl_error());

Please help me!

Thanks
~Satish

-----Original Message-----
From: acti...@listserv.ActiveState.com
[mailto:acti...@listserv.ActiveState.com] On Behalf Of Meuschel,
Hansjoerg
Sent: Tuesday, January 25, 2005 6:25 AM
To: Waghmare, Satish (IE03x)
Cc: acti...@listserv.ActiveState.com
Subject: RE: Perl-Oracel-error


The error message is technically correct, but it hides the real problem: The
DBD/Oracle/Oracle.dll works well, but it can't load the proper Oracle Call
Interface DLL OCIW32.DLL. Either there is not exactly one OCIW32.DLL, or the
PATH environment variable is not set correctly. The directory containing
OCIW32.DLL must be listed in the PATH enviroment variable for all users. Due
to Windows internals, the directory containing OCIW32.DLL must be listed in
the PATH environment variable. And as services usually do not use the
account you use to login to Windows, you need to change the system-wide PATH
settings. The location of this setting varies with the Windows version. For
Windows 2000, open Control Panel -> System -> Advanced -> Environment
variables and edit the system variables. Example: Change
C:\WINNT;C:\WINNT\SYSTEM; to C:\ORANT\BIN;C:\WINNT;C:\WINNT\SYSTEM;). Reboot
after changing the environment variables for services. The ORACLE_HOME
environment variable must point to t!  he directroy where Oracle is
installed, for all users. Some Oracle installations work fine without
ORACLE_HOME, some don't. Setting ORACLE_HOME does not hurt. The value of
ORACLE_HOME is the base directory of the Oracle installation. You usually
can derive it from the location of OCIW32.DLL, it is
ORACLE_HOME\bin\OCIW32.DLL. Setting ORACLE_HOME is very similar to changing
the PATH variable. Please see above. Reboot after changing the environment
variables for services.

 -----Original Message-----
From: acti...@listserv.ActiveState.com
[mailto:acti...@listserv.ActiveState.com]On Behalf Of Waghmare,
Satish (IE03x)
Sent: Tuesday, January 25, 2005 3:16 PM
To: cli...@globalmagic.com; acti...@listserv.ActiveState.com
Cc: acti...@listserv.ActiveState.com
Subject: RE: Perl-Oracel-error


Hi

'C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll' the file is present and I have
installed Oracle8i Server on machine.

Thanks
Satish
-----Original Message-----
From: cli...@globalmagic.com [mailto:cli...@globalmagic.com] 
Sent: Tuesday, January 25, 2005 6:03 AM
To: Waghmare, Satish (IE03x); acti...@listserv.ActiveState.com
Cc: acti...@listserv.ActiveState.com
Subject: Re: Perl-Oracel-error


have you checked that the 'C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll' is
actually there?  If not, you can copy it from where ever it did get loaded
into the folder it is OR add the folder it actually resides in to the INC
path
----- Original Message ----- 
From: Waghmare, Satish (IE03x) 
To: acti...@listserv.ActiveState.com 
Cc: acti...@listserv.ActiveState.com 
Sent: Tuesday, January 25, 2005 8:21 AM
Subject: Perl-Oracel-error


Hi 
I have succssfully Installed 'DBI' version 1.43  and  'DBD-Oracle' version
1.15 in ActivePerl 5.8.3.809 from
http://ftp.esoftmatic.com/outgoing/DBI/5.8.3/ link. But I installed I tried
connecting to oracle database using PERL script 
My Perl Script:- 
#!/usr/local/bin/perl -w 
#This will read a table called emp with two columns, fname and lname. 
use strict; 
use DBI; 
my @data; 
    my ($dbh, $sth, @rows, $firstname, $lastname); 
# connect to the database 
    $dbh = DBI->connect('dbi:Oracle:','scott', 'tiger') 
        or die "Couldn't connect to database: " . DBI->errstr; 
# prepare an SQL statement 
    $sth = $dbh->prepare(' 
        SELECT * FROM emp ORDER BY lname 
    ') or die "Couldn't prepare statement: " . $dbh->errstr; 
# execute the SQL statement 
    $sth->execute() 
        or die "Couldn't execute statement: " . $dbh->errstr; 
# Read the matching records and print them out          
    while (@data = $sth->fetchrow_array()) { 
        $firstname = $data[1]; 
        $lastname = $data[2]; 
        print "\t$$firstname $lastname\n"; 
    } 
# disconnect from the database 
    $dbh->disconnect 
But I'm getting an following error and error message box :- 
<<...OLE_Obj...>> 
C:\>perl o.pl 
install_driver(Oracle) failed: Can't load
'C:/Perl/site/lib/auto/DBD/Oracle/Oracle.dll' for module DBD::Oracle:
load_file:The specified module could not be found at
C:/Perl/lib/DynaLoader.pm line 229. at (eval 1) line 3 Compilation failed in
require at (eval 1) line 3. 
Perhaps a required shared library or dll isn't installed where expected at
o.pl line 12 
Thanks!! 


Best Regards, 
Satish Waghmare  



_______________________________________________
ActivePerl mailing list
Acti...@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs 
 
Please inform us immediately if this e-mail and/or any attachment was 
transmitted incompletely or was not intelligible.
___________________________________________________________________________
 
This e-mail and any attachment is for authorized use by the intended 
recipient(s) only. It may contain proprietary material, confidential 
information and/or be subject to legal privilege. It should not be copied, 
disclosed to, retained or used by any other party. 
If you are not an intended recipient then please promptly delete this 
e-mail and any attachment and all copies and inform the sender. 

_______________________________________________
ActivePerl mailing list
Acti...@listserv.ActiveState.com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs

Recent Messages in this Thread
Waghmare, Satish (IE03x) Jan 27, 2005 06:02 am