On Mon, 31 May 2004 23:54:34 GMT, Darin McBride
<dm******@naboo.to.org.no.spam.for.me> wrote:
Excluded_Middle wrote:
Hi,
I am trying to connect to db2 database and want to execute some basic
SQL commands like create or select.
I am on linux 7 redhat distribution and I have no rights to compile
perl or install some thing that is big in size as I am student.
If you cannot get DB2 installed on the machine, then there's not much
anyone can do except suggest you get a Linux box at home. I've heard
you can get this all running on Windows, too, if that's what you have
at home, but I wouldn't personally want to go there.
Assuming that DB2 is already installed, you can simply get the DBI and
DBD::DB2 modules installed in a private, local directory, and you can
use it with the perl that is already installed with RH7. You don't
need root access to install a private module, nor do you need to
compile/install the entire perl privately. I presume you can do
similarly with php, but I'm not proficient with that language.
I just want to experiment db2 and php or perl.
any link or suggestions ?
Thank you to all in advance.
Getting db2 working with php does require compilation of php. It can be
installed as a module. You will need the headers from the Workgroup or
developer edition in the include directory of your db2 install. You can
get the php source into your directory and then you compile just the odbc
module with the "--with-ibm-db2=shared,/opt/IBM/db2/V8.1" configuration
flag and put the resulting odbc.so in your local directory. You can then
load this in your php code with the dl() function. I believe this may
require php to be compiled with module support allthough I think that is
the default. I agree with Darin though, getting a linux box at home would
be the best bet. Nothing beats having full control of a machine for this
sort of testing.
--
Todd Huish