The PHP function oci_connect (which connects to an Oracle database) just returns false if it fails, which at the moment I handle like this:
$connection = oci_connect($username, $password, $database); if (!$connection){ return $result = 'Trouble connecting to the Oracle Database'; }
But really I’d like to have the actual ORA error code, so I can be more informative. Is this possible?
Have you tried examining the results of oci_error()?
I haven’t used Oracle with PHP (sadly) but the MySQL the general pattern is:
It seems logical that the Oracle pattern would be: