summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <ingo@mysql.com>2005-06-24 19:47:18 +0200
committerunknown <ingo@mysql.com>2005-06-24 19:47:18 +0200
commit2e6d41d13202d7c7756e502592340295af1684eb (patch)
treeafb4dd093ca8e3fdf8832f455c54e2b835bf00f8 /mysql-test
parentbe3d7091703c73686e4d6097734245a40151c276 (diff)
parenta7e66efc2cc37b8ca32868ac8c8e3e3c05675e48 (diff)
downloadmariadb-git-2e6d41d13202d7c7756e502592340295af1684eb.tar.gz
Bug#10178 - failure to find a row in heap table by concurrent UPDATEs
Bug#10568 - Function 'LAST_DAY(date)' does not return NULL for invalid argument. Manual merge. include/my_global.h: Auto merged mysql-test/t/heap_hash.test: Auto merged sql/ha_heap.h: Auto merged sql/item_timefunc.cc: Auto merged mysql-test/r/func_time.result: Manual merge. Used local for the backported fix for Bug#10568. mysql-test/r/heap_hash.result: Bug#10178 - failure to find a row in heap table by concurrent UPDATEs Manual merge. mysql-test/t/func_time.test: Manual merge. Used local for the backported fix for Bug#10568. sql/ha_heap.cc: Bug#10178 - failure to find a row in heap table by concurrent UPDATEs Manual merge.
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/heap_hash.result23
-rw-r--r--mysql-test/t/heap_hash.test2
2 files changed, 14 insertions, 11 deletions
diff --git a/mysql-test/r/heap_hash.result b/mysql-test/r/heap_hash.result
index 9720fe4843a..346fdd640ca 100644
--- a/mysql-test/r/heap_hash.result
+++ b/mysql-test/r/heap_hash.result
@@ -231,18 +231,19 @@ explain select * from t1 where a='aaad';
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ref a a 8 const 1 Using where
insert into t1 select * from t1;
+flush tables;
explain select * from t1 where a='aaaa';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaab';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaac';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaad';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
flush tables;
explain select * from t1 where a='aaaa';
id select_type table type possible_keys key key_len ref rows Extra
@@ -261,16 +262,16 @@ delete from t1;
insert into t1 select * from t2;
explain select * from t1 where a='aaaa';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaab';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaac';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
explain select * from t1 where a='aaad';
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t1 ref a a 8 const 1 Using where
+1 SIMPLE t1 ref a a 8 const 2 Using where
drop table t1, t2;
create table t1 (
id int unsigned not null primary key auto_increment,
@@ -345,14 +346,14 @@ insert into t3 select name, name from t1;
show index from t3;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t3 1 a 1 a NULL NULL NULL NULL HASH
-t3 1 a 2 b NULL 15 NULL NULL HASH
+t3 1 a 2 b NULL 13 NULL NULL HASH
show index from t3;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t3 1 a 1 a NULL NULL NULL NULL HASH
-t3 1 a 2 b NULL 15 NULL NULL HASH
+t3 1 a 2 b NULL 13 NULL NULL HASH
explain select * from t1 ignore key(btree_idx), t3 where t1.name='matt' and t3.a = concat('',t1.name) and t3.b=t1.name;
id select_type table type possible_keys key key_len ref rows Extra
-1 SIMPLE t3 ref a a 44 const,const 6 Using where
+1 SIMPLE t3 ref a a 44 const,const 7 Using where
1 SIMPLE t1 ref heap_idx heap_idx 22 const 7 Using where
drop table t1, t2, t3;
create temporary table t1 ( a int, index (a) ) engine=memory;
diff --git a/mysql-test/t/heap_hash.test b/mysql-test/t/heap_hash.test
index 46669dd2b8f..21ac69ef3a1 100644
--- a/mysql-test/t/heap_hash.test
+++ b/mysql-test/t/heap_hash.test
@@ -169,6 +169,8 @@ explain select * from t1 where a='aaac';
explain select * from t1 where a='aaad';
insert into t1 select * from t1;
+# avoid statistics differences between normal and ps-protocol tests
+flush tables;
explain select * from t1 where a='aaaa';
explain select * from t1 where a='aaab';
explain select * from t1 where a='aaac';