diff options
author | unknown <msvensson@shellback.(none)> | 2006-05-18 19:26:53 +0200 |
---|---|---|
committer | unknown <msvensson@shellback.(none)> | 2006-05-18 19:26:53 +0200 |
commit | c295bd8082f007085955791b7c80a3cfd48fe8ba (patch) | |
tree | fa3c36900b925b6d9a4073e5258eda1518820398 | |
parent | 3e12f98aa58b5d5e22254d31268a0eaa031c78ab (diff) | |
download | mariadb-git-c295bd8082f007085955791b7c80a3cfd48fe8ba.tar.gz |
Move test that requires innodb to sp_trans
-rw-r--r-- | mysql-test/r/sp-security.result | 10 | ||||
-rw-r--r-- | mysql-test/r/sp.result | 16 | ||||
-rw-r--r-- | mysql-test/r/sp_trans.result | 26 | ||||
-rw-r--r-- | mysql-test/t/sp-security.test | 23 | ||||
-rw-r--r-- | mysql-test/t/sp.test | 17 | ||||
-rw-r--r-- | mysql-test/t/sp_trans.test | 39 |
6 files changed, 65 insertions, 66 deletions
diff --git a/mysql-test/r/sp-security.result b/mysql-test/r/sp-security.result index af4f1c16c56..73f0eaa1513 100644 --- a/mysql-test/r/sp-security.result +++ b/mysql-test/r/sp-security.result @@ -314,16 +314,6 @@ select * from db_bug14533.t1; ERROR 42000: SELECT command denied to user 'user_bug14533'@'localhost' for table 't1' drop user user_bug14533@localhost; drop database db_bug14533; -CREATE DATABASE db_bug7787; -use db_bug7787; -CREATE PROCEDURE p1() -SHOW INNODB STATUS; -Warnings: -Warning 1541 The syntax 'SHOW INNODB STATUS' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW ENGINE INNODB STATUS' instead. -GRANT EXECUTE ON PROCEDURE p1 TO user_bug7787@localhost; -DROP DATABASE db_bug7787; -drop user user_bug7787@localhost; -use test; ---> connection: root DROP DATABASE IF EXISTS mysqltest; diff --git a/mysql-test/r/sp.result b/mysql-test/r/sp.result index 5aa984bfa4e..6d524c066a3 100644 --- a/mysql-test/r/sp.result +++ b/mysql-test/r/sp.result @@ -4796,22 +4796,6 @@ i 0 drop table t3| drop procedure bug16887| -create table t3 (f1 int, f2 varchar(3), primary key(f1)) engine=innodb| -insert into t3 values (1,'aaa'),(2,'bbb'),(3,'ccc')| -CREATE FUNCTION bug13575 ( p1 integer ) -returns varchar(3) -BEGIN -DECLARE v1 VARCHAR(10) DEFAULT null; -SELECT f2 INTO v1 FROM t3 WHERE f1 = p1; -RETURN v1; -END| -select distinct f1, bug13575(f1) from t3 order by f1| -f1 bug13575(f1) -1 aaa -2 bbb -3 ccc -drop function bug13575; -drop table t3| drop procedure if exists bug16474_1| drop procedure if exists bug16474_2| delete from t1| diff --git a/mysql-test/r/sp_trans.result b/mysql-test/r/sp_trans.result index 4c17226a9b0..a5012673c12 100644 --- a/mysql-test/r/sp_trans.result +++ b/mysql-test/r/sp_trans.result @@ -530,3 +530,29 @@ count(*) drop table t3, t4| drop procedure bug14210| set @@session.max_heap_table_size=default| +CREATE DATABASE db_bug7787| +use db_bug7787| +CREATE PROCEDURE p1() +SHOW INNODB STATUS; | +Warnings: +Warning 1541 The syntax 'SHOW INNODB STATUS' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW ENGINE INNODB STATUS' instead. +GRANT EXECUTE ON PROCEDURE p1 TO user_bug7787@localhost| +DROP DATABASE db_bug7787| +drop user user_bug7787@localhost| +use test| +create table t3 (f1 int, f2 varchar(3), primary key(f1)) engine=innodb| +insert into t3 values (1,'aaa'),(2,'bbb'),(3,'ccc')| +CREATE FUNCTION bug13575 ( p1 integer ) +returns varchar(3) +BEGIN +DECLARE v1 VARCHAR(10) DEFAULT null; +SELECT f2 INTO v1 FROM t3 WHERE f1 = p1; +RETURN v1; +END| +select distinct f1, bug13575(f1) from t3 order by f1| +f1 bug13575(f1) +1 aaa +2 bbb +3 ccc +drop function bug13575| +drop table t3| diff --git a/mysql-test/t/sp-security.test b/mysql-test/t/sp-security.test index a8c3c0a22eb..e791729fac4 100644 --- a/mysql-test/t/sp-security.test +++ b/mysql-test/t/sp-security.test @@ -527,29 +527,6 @@ drop database db_bug14533; # -# BUG#7787: Stored procedures: improper warning for "grant execute" statement -# - -# Prepare. - -CREATE DATABASE db_bug7787; -use db_bug7787; - -# Test. - -CREATE PROCEDURE p1() - SHOW INNODB STATUS; - -GRANT EXECUTE ON PROCEDURE p1 TO user_bug7787@localhost; - -# Cleanup. - -DROP DATABASE db_bug7787; -drop user user_bug7787@localhost; -use test; - - -# # WL#2897: Complete definer support in the stored routines. # # The following cases are tested: diff --git a/mysql-test/t/sp.test b/mysql-test/t/sp.test index 8ccd954eeea..938ecb31439 100644 --- a/mysql-test/t/sp.test +++ b/mysql-test/t/sp.test @@ -5637,23 +5637,6 @@ drop table t3| drop procedure bug16887| # -# Bug#13575 SP funcs in select with distinct/group and order by can -# produce bad data -# -create table t3 (f1 int, f2 varchar(3), primary key(f1)) engine=innodb| -insert into t3 values (1,'aaa'),(2,'bbb'),(3,'ccc')| -CREATE FUNCTION bug13575 ( p1 integer ) -returns varchar(3) -BEGIN -DECLARE v1 VARCHAR(10) DEFAULT null; -SELECT f2 INTO v1 FROM t3 WHERE f1 = p1; -RETURN v1; -END| -select distinct f1, bug13575(f1) from t3 order by f1| -drop function bug13575; -drop table t3| - -# # BUG#16474: SP crashed MySQL # (when using "order by localvar", where 'localvar' is just that. # diff --git a/mysql-test/t/sp_trans.test b/mysql-test/t/sp_trans.test index 1ea32316f1e..325e11b1ec9 100644 --- a/mysql-test/t/sp_trans.test +++ b/mysql-test/t/sp_trans.test @@ -552,6 +552,45 @@ drop table t3, t4| drop procedure bug14210| set @@session.max_heap_table_size=default| +# +# BUG#7787: Stored procedures: improper warning for "grant execute" statement +# + +# Prepare. + +CREATE DATABASE db_bug7787| +use db_bug7787| + +# Test. + +CREATE PROCEDURE p1() + SHOW INNODB STATUS; | + +GRANT EXECUTE ON PROCEDURE p1 TO user_bug7787@localhost| + +# Cleanup. + +DROP DATABASE db_bug7787| +drop user user_bug7787@localhost| +use test| + +# +# Bug#13575 SP funcs in select with distinct/group and order by can +# produce bad data +# +create table t3 (f1 int, f2 varchar(3), primary key(f1)) engine=innodb| +insert into t3 values (1,'aaa'),(2,'bbb'),(3,'ccc')| +CREATE FUNCTION bug13575 ( p1 integer ) +returns varchar(3) +BEGIN +DECLARE v1 VARCHAR(10) DEFAULT null; +SELECT f2 INTO v1 FROM t3 WHERE f1 = p1; +RETURN v1; +END| +select distinct f1, bug13575(f1) from t3 order by f1| +drop function bug13575| +drop table t3| + # # BUG#NNNN: New bug synopsis |