Have you tried the built in Oracle functions in PHP?
http://us3.php.net/oracle
oracle_logon() may be useful here ...
Let me know if it works out for you.
Regards,
Matt.
-Original Message-
From: Y Al Hinai [mailto:[EMAIL PROTECTED]
Sent: Tuesday, June 10, 2003 8:03 PM
To: [EMAIL PROTECTED]
Subject: [PHP-DB] Help Please!! Oracle/PHP connection
Hey guys,
I would really appriciate it if someone can direct me with this problem.
On my laptop I have: Windows XP Professional, Oracle 9i Database, Oracle
Client Software, PHP4.3.1, and Apache server.
PHP and Apache work fine. Oracle i9 by itslef works fine too. However when
i tried to connect from PHP to Oracle using the following code:
---Code Start-
?php
$user =netuser;
$upasswd =netuser;
$dsn =CSSD;
$conn = odbc_connect($dsn,$user,$upasswd);
echo conn: $conn;
if ($conn = 0) {
echo Error in connectionBR;
exit;
}
else {
echo PConnection successful\n;
}
odbc_Close($conn);
?
Code End--
I get the following error:
xxError Start
Warning: SQL error: [Microsoft][ODBC Driver Manager] Data source name not
found and no default driver specified, SQL state IM002 in SQLConnect in
C:\Documents and Settings\Administrator\My Documents\php\project\php14.tmp
on line 5
conn: Error in connection
xxError End
I have already set up the ODBC by going to Administrative Tools - Data
Sources (ODBC) - User DSN - and added an Oracle in OraHome92 driver for
my database.
Please help me out guys. This is for my Master's Thesis project.
Appriciated,
Yousef
-
Do you Yahoo!?
Free online calendar with sync to Outlook(TM).
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php