MySQL Forums
Forum List  »  Stored Procedures

problem with DECLARE CONTINUE HANDLER
Posted by: Federico Razzoli
Date: August 21, 2012 10:55AM

I'm using this piece of code in a Stored Procedure:

DECLARE CONTINUE HANDLER
FOR SQLWARNING, SQLEXCEPTION
CALL check_exception();

..and it works. But now I would like to add some statements, so I'm trying to add a BEGIN/END:

DECLARE CONTINUE HANDLER
FOR SQLWARNING, SQLEXCEPTION
BEGIN
CALL check_exception();
END;

This code causes a fatal error. Why? It sohuld be equivalent, shouldn't it?

I'm not posting the whole code because it's very large and contains sensitive information. However, I verified that this change that makes my code buggy.

Options: ReplyQuote


Subject
Views
Written By
Posted
problem with DECLARE CONTINUE HANDLER
2713
August 21, 2012 10:55AM


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.