http://www.perlmonks.org?node_id=1049144


in reply to Database Error Handling

You are checking for errors on the connect(), but not on the prepare, nor the execute. Use RaiseError on the connect, and then you don't have to check on any of them, it is taken care of for you.