RE: [PHP-DB] Problems with Oracle connections

From: Date: Thu, 29 Mar 2001 14:10:20 +0000
Subject: RE: [PHP-DB] Problems with Oracle connections
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-7976@lists.php.net to get a copy of this message
I belive you have to set your sid and oracle_home before attempting to ora_logon? putenv("ORACLE_SID=your sid); putenv("ORACLE_HOME=your oracle home); if(ora_plogon("rascunho@dvfpmm","java")) { echo "conectou"; } else { echo "falhou outra vez:".ora_error(); }") -----Original Message----- From: bgadelha [mailto:bgadelha@bol.com.br] Sent: Thursday, March 29, 2001 8:37 AM To: php-db@lists.php.net Subject: [PHP-DB] Problems with Oracle connections Hi, I'm having troubles using PHP+Oracle. I´m under Win98, with Apache WebServer, PHP4 and Oracle. When I try to connect, the following error message is displayed: Warning: Unable to connect to ORACLE (ORA-12154: TNS:could not resolve service name) in c:\apache\htdocs\testeoracle.php on line 24 falhou outra vez:ORA-12154: TNS:could not resolve service name Here is my code: <?php if(ora_plogon("rascunho@dvfpmm","java")) { echo "conectou"; } else { echo "falhou outra vez:".ora_error(); } phpinfo(INFO_ENVIRONMENT); ?> Can somebody help me? Thanks Bruno. __________________________________________________________________________ O BOL é Top3 no iBest! Vote já para torná-lo Top1! http://www.bol.com.br/ibest.html -- 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 (#7976) next »