1
0
mirror of https://github.com/MariaDB/server.git synced 2025-12-24 11:21:21 +03:00

Fixed BUG#8760: Stored Procedures: Invalid SQLSTATE is allowed in

a DECLARE ? HANDLER FOR stmt.
This commit is contained in:
pem@mysql.comhem.se
2005-02-28 18:07:06 +01:00
parent 07a87c9887
commit 54a2448bce
6 changed files with 105 additions and 5 deletions

View File

@@ -641,6 +641,44 @@ call bug6807()|
drop procedure bug6807|
#
# BUG#876: Stored Procedures: Invalid SQLSTATE is allowed in
# a DECLARE ? HANDLER FOR stmt.
#
--disable_warnings
drop procedure if exists bug8776_1|
drop procedure if exists bug8776_2|
drop procedure if exists bug8776_3|
drop procedure if exists bug8776_4|
--enable_warnings
--error ER_SP_BAD_SQLSTATE
create procedure bug8776_1()
begin
declare continue handler for sqlstate '42S0200test' begin end;
begin end;
end|
--error ER_SP_BAD_SQLSTATE
create procedure bug8776_2()
begin
declare continue handler for sqlstate '4200' begin end;
begin end;
end|
--error ER_SP_BAD_SQLSTATE
create procedure bug8776_3()
begin
declare continue handler for sqlstate '420000' begin end;
begin end;
end|
--error ER_SP_BAD_SQLSTATE
create procedure bug8776_4()
begin
declare continue handler for sqlstate '42x00' begin end;
begin end;
end|
drop table t1|