Commit 0233735d authored by unknown's avatar unknown

BUG#14702: misleading error message when syntax error in

           CREATE PROCEDURE

The bug was fixed already.  This changeset adds a test case.


mysql-test/r/sp-error.result:
  Add result for bug#14702: misleading error message when syntax error
  in CREATE PROCEDURE.
mysql-test/t/sp-error.test:
  Add test case for bug#14702: misleading error message when syntax error
  in CREATE PROCEDURE.
parent f9f3bc5d
......@@ -1174,3 +1174,16 @@ drop procedure bug15091;
drop function if exists bug16896;
create aggregate function bug16896() returns int return 1;
ERROR 42000: AGGREGATE is not supported for stored functions
DROP PROCEDURE IF EXISTS bug14702;
CREATE IF NOT EXISTS PROCEDURE bug14702()
BEGIN
END;
ERROR 42000: 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 'IF NOT EXISTS PROCEDURE bug14702()
BEGIN
END' at line 1
CREATE PROCEDURE IF NOT EXISTS bug14702()
BEGIN
END;
ERROR 42000: 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 'IF NOT EXISTS bug14702()
BEGIN
END' at line 1
......@@ -1706,6 +1706,28 @@ drop function if exists bug16896;
create aggregate function bug16896() returns int return 1;
#
# BUG#14702: misleading error message when syntax error in CREATE
# PROCEDURE
#
# Misleading error message was given when IF NOT EXISTS was used in
# CREATE PROCEDURE.
#
--disable_warnings
DROP PROCEDURE IF EXISTS bug14702;
--enable_warnings
--error ER_PARSE_ERROR
CREATE IF NOT EXISTS PROCEDURE bug14702()
BEGIN
END;
--error ER_PARSE_ERROR
CREATE PROCEDURE IF NOT EXISTS bug14702()
BEGIN
END;
#
# BUG#NNNN: New bug synopsis
#
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment