473,388 Members | 1,496 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Connecting with Perl to Oracle

I’m trying to connect with perl DBD::Oracle on Windows to Oracle DB (Linux).

I compiled the Oracle.dll using the commands “perl Makefile.pl” “nmake” and “nmake install”, but when I try to connect to the DB, I get the following runtime error:

“R6034 an application has made an attempt to load the C Runtime library incorrectly.
Please contact the applications’ support team for more information.”

I suspect that I mixed the versions of VC compiler/Linker, when creating the Oracle.dll.

Here are the important env variables:
Expand|Select|Wrap|Line Numbers
  1. INCLUDE=C:\Program Files\Microsoft Visual Studio 8\VC\INCLUDE;;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Include
  2. LIB=C:\Program Files\Microsoft Visual Studio 8\VC\LIB;C:\Program Files\Microsoft
  3.  Visual Studio 8\SDK\v2.0\lib;;C:\Program Files\Microsoft Visual Studio 8\VC\LIB;C:\Program Files\Microsoft Platform SDK for Windows Server 2003 R2\Lib
  4. LIBPATH=C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727
  5. Path=C:\Program Files\Microsoft Visual Studio 8\Common7\IDE;C:\Program Files\Microsoft Visual Studio 8\VC\BIN;C:\Program Files\Microsoft Visual Studio 8\Common7\Tools;C:\Program Files\Microsoft Visual Studio 8\SDK\v2.0\bin;C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727;C:\Program Files\Microsoft Visual Studio 8\VC\VCPackages;C:\Perl\bin\;C:\Perl\bin\;C:\Perl\site\bin;C:\Perl\bin;c:\Perl_ActiveState\site\bin;c:\Perl_ActiveState\bin;D:\oracle\product\10.2.0\client_1\bin;C:\Oracle9i\bin;C:\Orant\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\Program Files\TELSTRA\Utils;c:\Program Files\Rational\common;C:\Program Files\IBM\Installation Manager\eclipse\lib;C:\Program Files\OpenVPN\bin
here is my code:

Expand|Select|Wrap|Line Numbers
  1. use DBI qw(:sql_types);
  2.  use DBD::Oracle;
  3.  
  4.  my $DB_Username     = "xxxx";
  5.  my $DB_Password     = "xxxxx";
  6.  my $DB_Type         = "";
  7.  my $DB_Handle       = "";
  8.  my $DB_Host         = "1.2.3.4";
  9.  my $DB_Sid          = "DBSID";
  10.  my $DB_DSN          = "DBI:Oracle:RAMDB";
  11.  
  12.   my $dbh = DBI->connect($DB_DSN, $DB_Username, $DB_Password) || die ("can't connect to DB \n");
  13.  
Does anyone has a suggestion as to how to debug it , or fix it ?
Feb 27 '08 #1
1 2738
eWish
971 Expert 512MB
If you are on a windows machine and using ActiveState, you can use the PPM utility to install the DBD::Oracle module for you. Try that and see if it corrects your problems.


Also, please use Code tags when posting code here. Thank You.

--Kevin
Feb 27 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Keith | last post by:
All: What is the difference between Perl (CGI) and PHP (Apache module)? I thought both used servers to direct the user to the appropiate Perl or PHP program in order to execute the program to...
0
by: Kong Li | last post by:
Follow up to this thread, the latest Oracle 9i release 2 patchset (9.2.0.5) fixed the handle count leak problem. The problem is in Oracle client component. Thanks. Kong ----- From: Kong...
1
by: Martin_Hurst | last post by:
Is it possible to establish a connection from within a postgres database to another external database on the network, i.e., not a java or scripting connection, BUT by some type of table definition...
2
by: msnesw.microsoft.com | last post by:
I developed a web application about a year ago that connects to the Oracle DB using MS ODBC for Oracle. But I had to move the whole application to a brand-new PC . When I try to run I get the...
2
by: rcc.gamer | last post by:
Hello All, I am trying to connect a GridView to an Oracle table using the standard SqlDataSource. The process is fairly simple and there are detailed instructions from Microsoft ......
4
by: billb | last post by:
I installed a perl extension for PHP to use some perl inside my php primarily because I have perl working with oracle and not php and oracle. So I want to use my old perl scripts, and use the...
3
by: hakiran | last post by:
Hello all, I have been using Perl DBI the last 6months or so. I use it extensively with MySQL. But recently i tried to access Oracle DB with it and was having trouble. Any help would be...
3
by: andrewkl | last post by:
hi, I have the following Perl code that inserts a string to an Oracle DB via a stored procedure: #!/usr/local/bin/perl ## Perl v5.8.6 built for sun4-solaris use strict; BEGIN...
17
by: kanishka1213 | last post by:
when i run perl script in the cmd prompt , it runs well and outputs results from db. but when i run the same script on apache server internet explorer. i get an error as -----...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.