Reputation: 212
I could not connect oracle with cakephp2, After search a few hour i found and followed link step by step still not success, my oracle 11g
error:
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
Upvotes: 0
Views: 1321
Reputation: 212
I found solution with many errors, here what i fixed: (Note still follow this link)
How to fix:
public $dboracle = array( 'datasource' => 'Database/Oracle', 'driver' => 'oracle', 'connect' => 'oci_connect', 'persistent' => true, 'host' => "your host database ip", 'login' => 'db user name', 'password' => 'db password', 'database' => '(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=you db ip )(PORT=1521)) (CONNECT_DATA=(SID= you sid)))', 'prefix' => '', 'schema' => 'schema_name' );
Upvotes: 1
Reputation: 8451
First, the ORA error is a permutation of the ORA-12514: TNS listener cannot resolve service name error as shown below. This form of the ORA-12541 error commonly happens when the database or the listener processes are in the middle of a startup, or when the database (mysid in your case) has not been registered with the listener.
root> oerr ora 12514
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
Cause:
Action:
If an easy connect naming connect identifier was used, check that the service name specified is a service known by the listener.
Check for an event in the listener.log file.
Upvotes: 0