diff options
author | pem@mysql.comhem.se <> | 2004-07-21 14:53:09 +0200 |
---|---|---|
committer | pem@mysql.comhem.se <> | 2004-07-21 14:53:09 +0200 |
commit | c0ae84125825e5fb28b4872008ce984e70ae8166 (patch) | |
tree | 9c4a5fbacf4edbc4b2994c620f5d4a69b951f7d6 /mysql-test/r/sp-error.result | |
parent | 108be666d98c25108d4209cc582798a1e25d0b0a (diff) | |
download | mariadb-git-c0ae84125825e5fb28b4872008ce984e70ae8166.tar.gz |
Fixed BUG#2653: Undeclared variables not detected in stored procedures.
We now get an run-time error instead of a crash (although a slightly misleading
error message, but it's an improvement).
Diffstat (limited to 'mysql-test/r/sp-error.result')
-rw-r--r-- | mysql-test/r/sp-error.result | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/mysql-test/r/sp-error.result b/mysql-test/r/sp-error.result index d44360d9b5c..2b6f0826326 100644 --- a/mysql-test/r/sp-error.result +++ b/mysql-test/r/sp-error.result @@ -397,4 +397,20 @@ drop procedure bug3279| drop table t3| create procedure nodb.bug3339() begin end| ERROR 42000: Unknown database 'nodb' +create procedure bug2653_1(a int, out b int) +set b = aa| +create procedure bug2653_2(a int, out b int) +begin +if aa < 0 then +set b = - a; +else +set b = a; +end if; +end| +call bug2653_1(1, @b)| +ERROR 42S22: Unknown column 'aa' in 'order clause' +call bug2653_2(2, @b)| +ERROR 42S22: Unknown column 'aa' in 'order clause' +drop procedure bug2653_1| +drop procedure bug2653_2| drop table t1| |