diff options
author | unknown <bell@sanja.is.com.ua> | 2004-10-21 23:56:12 +0300 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2004-10-21 23:56:12 +0300 |
commit | e6e1600ec93ae95dbb17a9e462ca1abd7e715396 (patch) | |
tree | adba151b89c3f3b0d8b6812947bd34aa47f36a7d /mysql-test | |
parent | ec8779e95a46b3dfff492196ad004cb2716df3c3 (diff) | |
download | mariadb-git-e6e1600ec93ae95dbb17a9e462ca1abd7e715396.tar.gz |
Check of temporary tables hiding for query fetched from QC (BUG#6084)
mysql-test/r/query_cache.result:
hiding real table stored in query cache by temporary table
mysql-test/t/query_cache.test:
hiding real table stored in query cache by temporary table
sql/sql_cache.cc:
Check of temporary tables hiding for query fetched from QC
sql/sql_cache.h:
Key length now stored in table record of query cache
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/query_cache.result | 13 | ||||
-rw-r--r-- | mysql-test/t/query_cache.test | 12 |
2 files changed, 25 insertions, 0 deletions
diff --git a/mysql-test/r/query_cache.result b/mysql-test/r/query_cache.result index a9e9f167e5f..85fe77b1f10 100644 --- a/mysql-test/r/query_cache.result +++ b/mysql-test/r/query_cache.result @@ -704,4 +704,17 @@ Qcache_queries_in_cache 1 unlock table; drop table t1,t2; set query_cache_wlock_invalidate=default; +CREATE TABLE t1 (id INT PRIMARY KEY); +insert into t1 values (1),(2),(3); +select * from t1; +id +1 +2 +3 +create temporary table t1 (a int not null auto_increment +primary key); +select * from t1; +a +drop table t1; +drop table t1; set GLOBAL query_cache_size=0; diff --git a/mysql-test/t/query_cache.test b/mysql-test/t/query_cache.test index 8a07c0a53a0..61fbadde1e1 100644 --- a/mysql-test/t/query_cache.test +++ b/mysql-test/t/query_cache.test @@ -521,4 +521,16 @@ unlock table; drop table t1,t2; set query_cache_wlock_invalidate=default; +# +# hiding real table stored in query cache by temporary table +# +CREATE TABLE t1 (id INT PRIMARY KEY); +insert into t1 values (1),(2),(3); +select * from t1; +create temporary table t1 (a int not null auto_increment +primary key); +select * from t1; +drop table t1; +drop table t1; + set GLOBAL query_cache_size=0; |