Commit 985e4a64 authored by unknown's avatar unknown

after merge fix

parent 95a8bb20
...@@ -1650,88 +1650,11 @@ a (select count(*) from t2) ...@@ -1650,88 +1650,11 @@ a (select count(*) from t2)
3 0 3 0
4 0 4 0
drop table t1,t2; drop table t1,t2;
DROP DATABASE IF EXISTS bug30269;
FLUSH STATUS;
CREATE DATABASE bug30269;
USE bug30269;
CREATE TABLE test1 (id int, name varchar(23));
CREATE VIEW view1 AS SELECT * FROM test1;
INSERT INTO test1 VALUES (5, 'testit');
GRANT SELECT (id) ON TABLE bug30269.test1 TO 'bug30269'@'localhost';
GRANT SELECT ON TABLE bug30269.view1 TO 'bug30269'@'localhost';
set global query_cache_size= 81920;
USE bug30269;
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 0
# Select statement not stored in query cache because of column privileges.
SELECT id FROM test1 WHERE id>2;
id
5
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 0
SELECT id FROM view1 WHERE id>2;
id
5
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 1
DROP DATABASE bug30269;
DROP USER 'bug30269'@'localhost';
set GLOBAL query_cache_type=default; set GLOBAL query_cache_type=default;
set GLOBAL query_cache_limit=default; set GLOBAL query_cache_limit=default;
set GLOBAL query_cache_min_res_unit=default; set GLOBAL query_cache_min_res_unit=default;
set GLOBAL query_cache_size=default; set GLOBAL query_cache_size=default;
End of 5.0 tests End of 5.0 tests
drop database if exists db1;
drop database if exists db2;
set GLOBAL query_cache_size=15*1024*1024;
create database db1;
use db1;
create table t1(c1 int)engine=myisam;
insert into t1(c1) values (1);
select * from db1.t1 f;
c1
1
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 1
rename schema db1 to db2;
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 0
drop database db2;
set global query_cache_size=default;
drop database if exists db1;
drop database if exists db3;
set GLOBAL query_cache_size=15*1024*1024;
create database db1;
create database db3;
use db1;
create table t1(c1 int) engine=myisam;
use db3;
create table t1(c1 int) engine=myisam;
use db1;
insert into t1(c1) values (1);
use mysql;
select * from db1.t1;
c1
1
select c1+1 from db1.t1;
c1+1
2
select * from db3.t1;
c1
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 3
rename schema db1 to db2;
show status like 'Qcache_queries_in_cache';
Variable_name Value
Qcache_queries_in_cache 1
drop database db2;
drop database db3;
CREATE TABLE t1 (a ENUM('rainbow')); CREATE TABLE t1 (a ENUM('rainbow'));
INSERT INTO t1 VALUES (),(),(),(),(); INSERT INTO t1 VALUES (),(),(),(),();
SELECT 1 FROM t1 GROUP BY (SELECT 1 FROM t1 ORDER BY AVG(LAST_INSERT_ID())); SELECT 1 FROM t1 GROUP BY (SELECT 1 FROM t1 ORDER BY AVG(LAST_INSERT_ID()));
...@@ -1741,7 +1664,7 @@ DROP TABLE t1; ...@@ -1741,7 +1664,7 @@ DROP TABLE t1;
CREATE TABLE t1 (a LONGBLOB); CREATE TABLE t1 (a LONGBLOB);
INSERT INTO t1 SET a = 'aaaa'; INSERT INTO t1 SET a = 'aaaa';
INSERT INTO t1 SET a = 'aaaa'; INSERT INTO t1 SET a = 'aaaa';
SELECT 1 FROM t1 GROUP BY SELECT 1 FROM t1 GROUP BY
(SELECT LAST_INSERT_ID() FROM t1 ORDER BY MIN(a) ASC LIMIT 1); (SELECT LAST_INSERT_ID() FROM t1 ORDER BY MIN(a) ASC LIMIT 1);
1 1
1 1
......
...@@ -1250,8 +1250,6 @@ disconnect user1; ...@@ -1250,8 +1250,6 @@ disconnect user1;
disconnect user2; disconnect user2;
disconnect user3; disconnect user3;
--echo End of 5.0 tests
# #
# Bug #28211 RENAME DATABASE and query cache don't play nicely together # Bug #28211 RENAME DATABASE and query cache don't play nicely together
# #
...@@ -1300,6 +1298,8 @@ set GLOBAL query_cache_limit=default; ...@@ -1300,6 +1298,8 @@ set GLOBAL query_cache_limit=default;
set GLOBAL query_cache_min_res_unit=default; set GLOBAL query_cache_min_res_unit=default;
set GLOBAL query_cache_size=default; set GLOBAL query_cache_size=default;
--echo End of 5.0 tests
# #
# Bug #31157: Crash when select+order by the avg of some field within the # Bug #31157: Crash when select+order by the avg of some field within the
# group by # group by
......
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