diff options
author | unknown <pem@mysql.com> | 2005-09-29 16:59:25 +0200 |
---|---|---|
committer | unknown <pem@mysql.com> | 2005-09-29 16:59:25 +0200 |
commit | 9b74b04671d66b80305fc8123b0182eadb11d891 (patch) | |
tree | 37b3a3f8236750a6553aee500a8ca2982e220d14 /mysql-test/t/sp.test | |
parent | 4c19f0e9d49152ee005d83614502b1dd06548cf1 (diff) | |
parent | b262e64316cd278bdebe830118fcc5c3d56254b6 (diff) | |
download | mariadb-git-9b74b04671d66b80305fc8123b0182eadb11d891.tar.gz |
Merge mysql.com:/usr/local/bk/mysql-5.0
into mysql.com:/home/pem/work/mysql-5.0
mysql-test/r/sp.result:
This will be regenerated...
mysql-test/t/sp.test:
Manual merge.
Diffstat (limited to 'mysql-test/t/sp.test')
-rw-r--r-- | mysql-test/t/sp.test | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/mysql-test/t/sp.test b/mysql-test/t/sp.test index 67fb165d4f4..36a77545f8b 100644 --- a/mysql-test/t/sp.test +++ b/mysql-test/t/sp.test @@ -4265,6 +4265,56 @@ drop procedure bug6127| # +# BUG#12589: Assert when creating temp. table from decimal stored procedure +# variable +# +--disable_warnings +drop procedure if exists bug12589_1| +drop procedure if exists bug12589_2| +drop procedure if exists bug12589_3| +--enable_warnings +create procedure bug12589_1() +begin + declare spv1 decimal(3,3); + set spv1= 123.456; + + set spv1 = 'test'; + create temporary table tm1 as select spv1; + show create table tm1; + drop temporary table tm1; +end| + +create procedure bug12589_2() +begin + declare spv1 decimal(6,3); + set spv1= 123.456; + + create temporary table tm1 as select spv1; + show create table tm1; + drop temporary table tm1; +end| + +create procedure bug12589_3() +begin + declare spv1 decimal(6,3); + set spv1= -123.456; + + create temporary table tm1 as select spv1; + show create table tm1; + drop temporary table tm1; +end| + +# Note: The type of the field will match the value, not the declared +# type of the variable. (This is a type checking issue which +# might be changed later.) + +# Warning expected from "set spv1 = 'test'", the value is set to decimal "0". +call bug12589_1()| +# No warnings here +call bug12589_2()| +call bug12589_3()| + +# # BUG#7049: Stored procedure CALL errors are ignored # --disable_warnings |