MySQL Forums
Forum List  »  Stored Procedures

Try-catch like mechanism in SP
Posted by: Pieter Huiberts
Date: June 12, 2012 02:47PM

Hello,
I am looking for a Try-CATCH like behavior in MySQL, with different types of action depending on success of a particular action. In other words, I need to know whether a particular SQL-statment run well or not by simply returning a Boolean. The feedback is required for reporting purposes in an error log table. My SP would execute well and report normal stats, but if for exampela table fails I need to write that error msg to the error log instead..


My thought is perhaps Prepared statements? can this return a Boolean? other suggestions?

Options: ReplyQuote


Subject
Views
Written By
Posted
Try-catch like mechanism in SP
4722
June 12, 2012 02:47PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.