MySQL calls via PDO fail silently

By default any error that occurs on a MySQL call via PDO fails quietly. The caller must inspect $pdo->errorCode() to see if the call succeeded/failed. This behaviour can be changed by setting the ATTR_ERRMODE attribute either while constructing the PDO object or after construction via setAttribute.