Issue with labeled BEGIN statement in stored procedure

Discussion of open issues, suggestions and bugs regarding database management and administration tools for MySQL
Post Reply
DarkMatters
Posts: 5
Joined: Thu 31 Jul 2008 15:07
Location: New York, NY
Contact:

Issue with labeled BEGIN statement in stored procedure

Post by DarkMatters » Mon 31 Aug 2009 22:35

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.

Alexz
Devart Team
Posts: 165
Joined: Wed 10 Aug 2005 08:30

Post by Alexz » Tue 01 Sep 2009 11:30

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.

DarkMatters
Posts: 5
Joined: Thu 31 Jul 2008 15:07
Location: New York, NY
Contact:

Post by DarkMatters » Tue 01 Sep 2009 16:14

thank you,
I am currently using 3.50.310.
I will try to upgrade.

Post Reply