各位大佬帮忙看看哪里有语法错误
CREATE PROCEDURE update_customer_code ()
BEGIN
DECLARE mysort INT;
DECLARE done tinyint;
DECLARE customerId VARCHAR;
DECLARE cur CURSOR FOR SELECT customer_id FROM customer_association_process;
OPEN cur;
WHILE done DO
FETCH cur INTO customerId;
CALL superior_splice (customerId);
SET mysort = mysort + 1;
END
WHILE;
CLOSE cur;
END;
错误提示:
[Err] 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '
SET mysort = 1;
DECLARE done tinyint;
SET done = 1;
D' at line 4