in reply to DBI fails to return an error code
Only use $DBI::err (and errstr) when connecting to a database.
Use $dbh->err (and $dbh->errstr) for actions performed using this $dbh.
When working with statement handles (like prepared queries), use $sth->err.
Always try to use the err-function in the smallest scope possible, because the rest can be altered by other parts running in your code (in other threads or wherever).
Use $dbh->err (and $dbh->errstr) for actions performed using this $dbh.
When working with statement handles (like prepared queries), use $sth->err.
Always try to use the err-function in the smallest scope possible, because the rest can be altered by other parts running in your code (in other threads or wherever).
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^2: DBI fails to return an error code
by mje (Curate) on Oct 05, 2011 at 16:56 UTC | |
by Neighbour (Friar) on Oct 06, 2011 at 08:27 UTC |
In Section
Seekers of Perl Wisdom