ID: 13526 Updated by: zak Reported By: [EMAIL PROTECTED] Old Status: Open Status: Duplicate Bug Type: OCI8 related Operating System: Linux( Suse 7 ) PHP Version: 4.0.6 New Comment:
Duplicate of bug #13526 Previous Comments: ------------------------------------------------------------------------ [2001-10-03 05:53:53] [EMAIL PROTECTED] The folowing precedures have been tested when connecting to a HP UX with Oracle 7.x using of couse the OCI8 as the client interface. Add those lines to the web server config files or set and export those ones before the web server starts. SetEnv ORACLE_HOME /usr/local/oracle SetEnv ORACLE_SID <sid> SetEnv LD_LIBRARY_PATH /usr/local/oracle/lib SetEnv TNS_ADMIN /usr/local/oracle/tnsnames.ora SetEnv TWO_TASK /usr/local/oracle/tnsnames.ora SetEnv NLS_LANG English_America.WE8ISO8859P1 SetEnv ORACLE_BASE /usr/local When calling the OCILogon do this: $db = " (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP) (HOST =server_ip_or_dns_name)(PORT = 1521)) (CONNECT_DATA= (SID = _sid_)) )"; The previous definition is a copy of the service definition that is stored in the tnsnames.ora file. Next, call the OCILogon function using the folowing format: OCILogon("user/password","password", $db); To avoid ORA-01005 error, set the NLS_LANG environment variable to English_America.WE8ISO8859P1 ( some other values may work...but we have found that this one works for us ). To avoid ORA-12154 and ORA-12505, use the service definition as the OCILogin third parameter. It seams that there are errors in the OCILogin function in the manual...please correct them. I hope these lines can help. Regards Miguel Carvalho ------------------------------------------------------------------------ Edit this bug report at http://bugs.php.net/?id=13526&edit=1 -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]