Aug 29, 2014, 10:02 AM
Post #1 of 7
[SOLVED] Perl DBI - Error handling
I have a little query utility web page where you can execute your queries, I am trying to capture error so that I can present it in a better way if something goes wrong with the execution, here's how I am trying to capture it:
if ( $sth->err )
die "There is something wrong with your query :" . $sth->err . " error msg: " . $sth->errstr . "\n";
But instead of display my msg its showing the following error:
Software error:Can't call method "execute" on an undefined value at /usr/share/nwind/cgi-bin/viewquerybuilder.pl line 91.
For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.
Many thanks for your help !
(This post was edited by terrykhatri531 on Aug 30, 2014, 2:51 AM)