| Bug #10935 | MySQL Test: Creation of a stored procedure having a comment in its body fails | ||
|---|---|---|---|
| Submitted: | 27 May 2005 21:56 | Modified: | 27 May 2005 23:13 |
| Reporter: | Disha | Email Updates: | |
| Status: | Not a Bug | Impact on me: | |
| Category: | MySQL Server | Severity: | S2 (Serious) |
| Version: | 5.0.5-beta-nt | OS: | Linux (Redhat Linux 9.0) |
| Assigned to: | CPU Architecture: | Any | |
[27 May 2005 21:56]
Disha
[27 May 2005 23:13]
MySQL Verification Team
Please see that you need to use delimiter // before the line
you begin to create the procedure:
miguel@hegel:~/dbs/5.0$ bin/mysql -uroot
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 3 to server version: 5.0.7-beta-debug
Type 'help;' or '\h' for help. Type '\c' to clear the buffer.
mysql> drop database if exists test1;
Query OK, 2 rows affected (0.03 sec)
mysql> Drop table if exists t1;
ERROR 1046 (3D000): No database selected
mysql> Create database test1;
Query OK, 1 row affected (0.00 sec)
mysql> Use test1;
Database changed
mysql> Create table t1(f1 int,f2 int);
Query OK, 0 rows affected (0.01 sec)
mysql> delimiter //
mysql> Create procedure sp1()
-> Begin
-> #Test comment;
-> Select * from t1;
-> End//
Query OK, 0 rows affected (0.01 sec)
mysql> show create procedure sp1//
+-----------+----------+--------------------------------------------------------------+
| Procedure | sql_mode | Create Procedure |
+-----------+----------+--------------------------------------------------------------+
| sp1 | | CREATE PROCEDURE `test1`.`sp1`()
Begin
Select * from t1;
End |
+-----------+----------+--------------------------------------------------------------+
1 row in set (0.00 sec)
mysql> call sp1()//
Empty set (0.01 sec)
Query OK, 0 rows affected (0.01 sec)
[13 Jul 2005 11:40]
Disha
This bug is a MySQLTest failure. This is a Test Suite Failure, where the test run crashes when scripts contains stored procedures with 'inline' comments.
