note 12350 deleted from function.ociplogon by sixd
| From: | sixd@php.net | Date: | Mon, 05 Oct 2009 01:21:26 +0000 |
| Subject: | note 12350 deleted from function.ociplogon by sixd | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-161271@lists.php.net to get a copy of this message | ||
Note Submitter: e dot v dot wijk at hetnet dot nl
----
The solution for not being able to connect to an Oracle database usually is setting the right system
variables (ORACLE_HOME, etc...). However, it often happens that you are still not able to connect,
even though these settings are correctly set.
If this is the case, try the following:
Instead of refering to the entry in the tnsnames.ora, use the actual string from the tnsnames.ora:
$User = "john"
$Password = "doe"
$Database = "(DESCRIPTION = ADDRESS_LIST (ADDRESS = (PROTOCOL= TCP (Host= yourhost) (Port=
1526)))(CONNECT_DATA = (SID = YourTnsSID )))";
OCIPLogon($User, $Password, $Database)
I hope this is helpfull for those strugling to connect to an Oracle database.
Edwin van Wijk