Do you have a question? Post it now! No Registration Necessary. Now with pictures!
June 10, 2011, 4:41 pm
rate this thread
array(PDO::ATTR_ERRMODE => PDO::ERRMODE_WARNING));
The above is supposed to set PDO to E_WARNING instead of PDO exception.
Yet it throws exception.
I know it is possible to do:
but this works only if connection has been established in the first place.
What if there is a connection error - then you are forced to handle
exceptions with try/catch block...
The same applies to PDO::ERRMODE_SILENT
Any solutions to setting error mode before connecting or is this a stupid