I put the code in and it worked perfectly. as it turns out there was a networking issue that I had not been informed of that was causing the problem. Thanks for your reply.
Robert W. Collins II Webmaster New Orleans Regional Transit Authority Phone : (504) 248-3826 Email : [EMAIL PROTECTED] -----Original Message----- From: Svensson, B.A.T. (HKG) [mailto:[EMAIL PROTECTED]] Sent: Thursday, April 11, 2002 3:23 PM To: Collins, Robert Cc: PHP Windows Subject: RE: [PHP-WIN] Problem Connecting to AS400 using ODBC What happens if you instrument your code in the following way: <? echo "SEGMENT TEST CONNECT: START"; $username = "USERNAME"; $password = "PASSWORD"; $dsn = "DSN"; if($conn = odbc_connect($dsn,$username,$password)){ echo "connected"; }else{ echo "failed"; } odbc_close($conn); echo "SEGMENT TEST CONNECT: STOP"; ?> > -----Original Message----- > From: Collins, Robert [mailto:[EMAIL PROTECTED]] > Sent: Thursday, April 11, 2002 9:15 PM > To: PHP Windows > Subject: [PHP-WIN] Problem Connecting to AS400 using ODBC > > > I am trying to access data on an AS/400(IBM DB2) from a windows platform > using Apache, and PHP. The problem I am having is that the script doesn't > appear to do anything, it will run constantly and doesn't produce an error > or time out. I have tried setting the ODBC DSN as both user and server. Has > anyone else had this problem, and if so what was the fix? > > Using : > Windows 2k o NT4 > PHP ver.4.1.1 > APACHE ver. 1.3.22 > Client Access ODBC Driver (32bit) ver. 7.00.00.00 > > Code Snippet: > <? > $username = "USERNAME"; > $password = "PASSWORD"; > $dsn = "DSN"; > if($conn = odbc_connect($dsn,$username,$password)){ > echo "connected"; > }else{ > echo "failed"; > } > odbc_close($conn); > ?> > -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php