Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Connect to DB2 Database with Perl DBI in Windows 7

by pme (Prior)
on Aug 17, 2015 at 19:42 UTC ( #1138923=note: print w/replies, xml ) Need Help??


in reply to Connect to DB2 Database with Perl DBI in Windows 7

Hi concerto5,

Welcome to the monastery!

Just install DBD::DB2 from http://www.cpan.org. Strawberry perl must have its own CPAN installer tool.

  • Comment on Re: Connect to DB2 Database with Perl DBI in Windows 7

Replies are listed 'Best First'.
Re^2: Connect to DB2 Database with Perl DBI in Windows 7
by concerto5 (Novice) on Aug 17, 2015 at 19:53 UTC
    Thanks for the reply. When installing in CPAN i get the following error: Failed during this command: IBMTORDB2/DBD-DB2-1.85.tar.gz : writemakefile NO 'C:\Strawberry\perl\bin\perl.exe Makefile.PL' returned status 512

      See this issue report, which suggests that the problem is because the code doesn't compile with the gcc bundled with Strawberry Perl.

      I believe that the core issue is gcc compiler support under Windows. T +here is a history here... that shows that in 2010, a patch was contributed +for DBD::DB2 1.78 for gcc on Windows. DBD::DB2 1.85, the current versio +n on CPAN, doesn't include this patch (or it no longer works).
      The way forward always starts with a minimal test.
        See this issue report, which suggests that the problem is because the code doesn't compile with the gcc bundled with Strawberry Perl.

        Should all attempts to compile DBD::DB2 fail, consider installing an ODBC driver for DB2 and use DBD::ODBC instead.

        Alexander

        --
        Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
        Thanks for all the help everyone. Will research what you've given me thus far and report back with any additional info.
      Can you see this message couple of lines above? "DB2_HOME environment variable must be set to installed location of DB2." This may be the reason. I have never used DB2.
        Yes you are right that is at the top. Does this mean I need to pass a DB2 installed location on my local machine? Would I actually have this by default on Windows?

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1138923]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others avoiding work at the Monastery: (7)
As of 2019-11-12 21:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Strict and warnings: which comes first?



    Results (66 votes). Check out past polls.

    Notices?