Re: Re: ibm db2 and php

From: Date: Fri, 28 Jul 2000 16:42:51 +0000
Subject: Re: Re: ibm db2 and php
Groups: php.db 
Request: Send a blank email to php-db+get-1609@lists.php.net to get a copy of this message
Yeah, that helped alot. My problem was that the db2instance variable wasn't getting set correctly, so I stuck the . line in one of the db2 startup files, and now it works fine. Thanks alot for the help, db2 works great now. -Ben Zeigler "Mirko Nalesso" To: Kelly.Setzer@ingramentertainment.com <okrim74@libe cc: php-db@lists.php.net ro.it> Subject: [PHP-DB] Re: ibm db2 and php 07/27/00 11:51 PM Hi There are few things to consider 1. I use php4 (last version) and I compile it --with-ibm-db2 option (before you must set LDFLAGS). 2. I put my odbcinst.ini and odbc.ini in /etc directory, since you will be connecting to system wide DSN's anyway.... 3. My .odbc.ini file is: [sample] Description = Test to DB2 Driver = DB2 and my odbcinst..ini file is: [ODBC] Trace = Yes Trace File = /tmp/sql_trace.log [DB2] Description = DB2 driver Driver = /usr/IBMdb2/V6.1/lib/libdb2.so FileUsage = 1 DontDLClose = 1 4. make sure you have DB@INSTANCE variable set up....the best thing to do is to execute "#. /home/db2inst1/sqllib/db2prifile" or put the equivalent into /etc/profile so evryone will be able to use it.... 6. Your odbcinst.ini driver must be libdb2.so: it's a shared lib; db2.o comes on AIX flavor..... I hope this helps.... Mirko. > On July 11, you posted a message on the php-db mailing list with the > following question: > > > If I write on a shell "php odbc.php3", there is the connection to > > database sample and right results appear. But if open a Netscape and > > open location > > "http://localhost.localdomain/odbc.php3" the results are: > > [...] > > My problem is: why does it work on shell and not on Netscape? > > Where can I find db2.o? > > Always thanks a lot. Mirko > > I have gone through the same process today and gotten the same results. > Did you ever find a solution? I have also noticed that the garbage I > get is not the same every time. > > thanks, > Kelly > -- > Kelly Setzer, Interstitial Engineering, Ingram Entertainment, Inc. > (615)287-4863 kelly.setzer@ingramentertainment.com > http://www.ingramentertainment.com > "Only those who dare to fail greatly can ever achieve greatly." -- JFK > > -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net For additional commands, e-mail: php-db-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.db (#1609) next »