Page 1 of 1

Issue with labeled BEGIN statement in stored procedure

Posted: Mon 31 Aug 2009 22:35
by DarkMatters
This is just an annoyance, not any functional issue. In MySQL you can label a BEGIN statement. Doing so causes the dbForge execute to think a parameter is being defined.


use test;

DROP PROCEDURE IF EXISTS test_syntax_issue;
DELIMITER $$
CREATE PROCEDURE test_syntax_issue (in _param_1 int)
SQL SECURITY INVOKER
READS SQL DATA
all_proc:BEGIN
if _param_1 is null then
leave all_proc;
end if;
select 'we can do something here' as 'message';
end;
$$
DELIMITER ;


Thanks for looking into this.

Posted: Tue 01 Sep 2009 11:30
by Alexz
We've tested your procedure on 5 and 6 MySQL servers and dbForge Studio for MySQL v3.60.351.
We couldn't reproduce this issue. Please, check if you have the latest version of dbForge Studio for MySQL. If you still reproduce this problem, please specify MySQL server version.

Posted: Tue 01 Sep 2009 16:14
by DarkMatters
thank you,
I am currently using 3.50.310.
I will try to upgrade.