beautypg.com

IBM Data Server DB2 User Manual

Page 215

background image

Chapter 4. Deploying applications with DB2

201

If you are using some other Perl distribution on Windows, you have to install
DBI manually. Download and uncompress the latest DBI from:

http://search.cpan.org/author/TIMB/DBI/

Example 4-40 shows how to install DBI for Windows for Perl distribution other
than ActiveState. The example assumes that you have uncompressed the
compressed file into a directory and you are currently in that directory.

Example 4-40 Installing DBI for Windows for Perl distribution other than ActiveState

perl Makefile.PL
nmake
nmake test
nmake install

IBM Data Server Driver for CLI support:

All Perl interfaces communicate to DB2 using CLI. You require IBM Data
Server Client to use the driver on Linux and UNIX. For Windows systems, you
can use IBM Data Server Driver for ODBC and CLI or IBM Data Server Driver
for ODBC, CLI, and .NET. Both are described in detail in 4.1.2, “IBM Data
Server Driver for ODBC, CLI, and .NET, and IBM Data Server Driver for
ODBC and CLI” on page 143.

Installation procedure for Linux and UNIX

To install DBD::DB2, download the source from:

http://www.cpan.org/authors/id/I/IB/IBMTORDB2/DBD-DB2-1.1.tar.gz

Uncompress the file in a directory. IBM Data Server Client is required to install it.
Example 4-41 shows the installation steps. The example assumes that
DB2_HOME is /opt/ibm/db2/V9.5.

Example 4-41 Installation commands for installing DBD::DB2

export DB2_HOME=/opt/ibm/db2/V9.5
perl Makefile.PL
make
make test
make install

Note: You might have to use

dmake

instead of

nmake

depending on the Perl

you are using. Refer to your Perl manual for more information.