Re: [PHP-DB] Re : Problem with PDO exceptions

[email protected] (Daniel Carrera)
Newsgroups php.db
Message-ID <[email protected]>
Neil Smith [MVP, Digital media] wrote:
> When you create your DB connection $db, follow the connection line 
> directly after with this :
> $db->setAttribute(PDO::ATTR_ERRMODE , PDO::ERRMODE_EXCEPTION);
> 
> The default is I believe PDO::ERRMODE_SILENT which is confusing to most 
> people the first time.


Thanks! It works now.

Cheers,
Daniel.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.