Link to home
Start Free TrialLog in
Avatar of hSindhu
hSindhu

asked on

install DBD-Oracle on Windows XP using PPM

Hi There,
I am attempting to install DBD-Oracle using ppm 4.0 on a Windows XP computer that has ActiveState version 5.10 installed. I could not do this successfully

These following are the attempts that I made to install the module:
1) Downloaded tar.gz file from CPAN and trying installing and landed into errors as I have no VC++.
2) Tried using PPM GUI interface to identify module and install but did not find the module
3) Tried using Cygwin to install and failed when ran "make"
4) Tried tweaking the make file to use MingW Compiler and landed into troubles.
5) In the command line typed
"ppm install DBD-Oracle"
"ppm install DBD::Oracle"
pm install failed: Can't find any package that provides DBD::Oracle

None of these work and results in the errors
Can anyone help me successfully install DBD::Oracle on Windows XP machine ?




#Sample code for reference
use strict;
use warnings;
use diagnostics;
use DBI qw(:sql_types);            # Load the DBI module
 
my $dbh = DBI->connect( "dbi:Oracle:test", "test", "test123" )
or die("Couldn't connect to the database \n");
&main();
 
sub main()
{
  print "successfully connected\n";   
}
 
Error Message:
install_driver(Oracle) failed: Can't locate DBD/Oracle.pm in @INC (@INC contains: C:/Personal/packages/eclipse/eclipse/workspaces/.metadata/.plugins/org.epic.debug C:/Personal/packages/eclipse/eclipse/workspaces/TELENOR_v1.0 C:/Perl/site/lib C:/Perl/lib .) at (eval 16)[C:/Perl/lib/DBI.pm:750] line 3.
Perhaps the DBD::Oracle perl module hasn't been fully installed,
or perhaps the capitalisation of 'Oracle' isn't right.
Available drivers: AnyData, CSV, DBM, ExampleP, File, Gofer, ODBC, Proxy, SQLRelay, SQLite, Sponge, Template, TemplateSS, XBase.
 at C:/Personal/packages/eclipse/eclipse/workspaces/TELENOR_v1.0/test.pl line 6
 at C:/Perl/lib/DBI.pm line 774
	DBI::install_driver('DBI', 'Oracle') called at C:/Perl/lib/DBI.pm line 620
	DBI::connect('DBI', 'dbi:Oracle:test', 'test', 'test123') called at C:/Personal/packages/eclipse/eclipse/workspaces/TELENOR_v1.0/test.pl line 6

Open in new window

Avatar of mjcoyne
mjcoyne

The Trouchelle repository has it.  See http://trouchelle.com/perl/ppmrepview.pl?id=11510.

To add Trouchelle to your repositories, follow the instructions at http://trouchelle.com/perl/ppmrepview.pl.

Why are you using such an old version of Perl?
Avatar of hSindhu

ASKER

I am having the latest version of Active State PERL 5.10.0.
Tried installing the ones you told but had no luck. Tried installing as per the directions in the website and get this error. Any ideas?

C:\Personal\packages>ppm install http://trouchelle.com/ppm/DBD-Oracle.ppd
ppm install failed: The PPD does not provide code to install for this platform
The version there is for perl 5.8.  I'm guessing it'll work with perl 5.10, but can't test here.

If you want to try installing it anyways:
Download this file, and the attached file.  save them to the same directory:
    http://trouchelle.com/ppm/MSWin32-x86-multi-thread-5.8/DBD-Oracle-1.19.zip

Rename the attached file to DBD-Oracle.ppd (eg: remove the .txt extension, which is required for uploading at EE)

Go to a command prompt, and go the directory you downloaded those files
Enter this command:   ppm install DBD-Oracle.ppd

DBD-Oracle.ppd.txt
Sorry -- for some reason, I read 5.10 as 5.01...:)
Avatar of hSindhu

ASKER

Hi Adam,

Thanks for sending the files. I still am having some problems. I installed the way you told and install went through fine. But when I tried using it in a small program this is what I get.

"The application has failed to start because perl58.dll was not found. Reinstalling the application may fix the problem".

I then fetched perl58.dll from TinyPerl application from the following website
http://tinyperl.sourceforge.net/
 and placed it in C:\Perl\bin folder

When I ran through the simple program again I got a wierd message

"The procedure entry point Perl_Ilockhook_ptr could not be located in
the dynamic link library perl58.dll."

I am assuming that the problem was that the Activestate-Perl-DBI.pm does not work together with the DBD::Oracle from . In http://trouchelle.com/DBI/ 

Is it that I would need the DBI.ppd as well so that both can go together?

Do let me know how I can get out of this problem. I am totally struck with this problem.

Thanks

The problem is that the DBI::Oracle module was designed for perl 5.8, and you have perl 5.10.  This is what prevented the auto-installation.  The instructions I gave were to allow you to try it anyway - but it isn't working.

You have a few options:
1) Install perl 5.8, and use the DBD::Oracle module at trouchelle
2) Find a pre-compiled DBD::Oracle module for perl version 5.10 (I don't know of one)
3) Compile the DBD::Oracle module for perl 5.10 yourself.

Option 1 is probably the easiest (unless you need perl 5.10 for some other reason).  From the ActiveState website, it looks like the basic distribution includes both perl 5.8 and perl 5.10 - so you might already have perl 5.8 installed somewhere.

For option 3, you will need to install a compiler.  I've never installed perl modules this way on a windows computer.  If you have Microsoft Visual Studio, then that comes with a compiler.  Otherwise, Microsoft has a free nmake program.  After installing a compiler, you would install the DBD::Oracle module using CPAN:
    (at a prompt)  perl -MCPAN -e "install DBD::Oracle"
Avatar of hSindhu

ASKER

Adam,

I followed suggestion 1 and this is the what I get

ppm install DBD-Oracle.ppd
ppm install failed: The PPD does not provide code to install for this platform

As well when I look at the PPD file it seems like it is for Version 5.10 and not 5.8.8
    <OS NAME="MSWin32" />
    <ARCHITECTURE NAME="MSWin32-x86-multi-thread-5.10" />

Not sure though.

I too dont have VC++ and hence am looking for a pre compiled package.

Let me know if there are other options.

Thanks
ASKER CERTIFIED SOLUTION
Avatar of Adam314
Adam314

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of hSindhu

ASKER

Hi Adam,

Great help! I am as well struggling to get a PADWalker for debugging on eclipse. I am hoping that it would not the same website you mentioned.

Thanks Again!