diff options
Diffstat (limited to 'mysql-test/suite/maria/maria.result')
-rw-r--r-- | mysql-test/suite/maria/maria.result | 86 |
1 files changed, 84 insertions, 2 deletions
diff --git a/mysql-test/suite/maria/maria.result b/mysql-test/suite/maria/maria.result index 1cf48b0628d..9c8565d0f03 100644 --- a/mysql-test/suite/maria/maria.result +++ b/mysql-test/suite/maria/maria.result @@ -653,7 +653,7 @@ t1 1 a 1 a A 1000 NULL NULL YES BTREE alter table t1 engine=heap; alter table t1 disable keys; Warnings: -Note 1031 Table storage engine for 't1' doesn't have this option +Note 1031 Storage engine MEMORY of the table `test`.`t1` doesn't have this option show keys from t1; Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment Index_comment t1 1 a 1 a NULL 500 NULL NULL YES HASH @@ -662,6 +662,13 @@ create table t1 ( a tinytext, b char(1), index idx (a(1),b) ); insert into t1 values (null,''), (null,''); explain select count(*) from t1 where a is null; id select_type table type possible_keys key key_len ref rows Extra +1 SIMPLE t1 ref idx idx 4 const 2 Using where +insert into t1 values(1,'a'); +explain select count(*) from t1 where a is null; +id select_type table type possible_keys key key_len ref rows Extra +1 SIMPLE t1 ref idx idx 4 const 2 Using where +explain select count(*) from t1 where a = 'a'; +id select_type table type possible_keys key key_len ref rows Extra 1 SIMPLE t1 ref idx idx 4 const 1 Using where select count(*) from t1 where a is null; count(*) @@ -1131,6 +1138,8 @@ id select_type table type possible_keys key key_len ref rows Extra alter table t1 add unique(v); ERROR 23000: Duplicate entry '{ ' for key 'v_2' alter table t1 add key(v); +Warnings: +Note 1831 Duplicate index `v_2`. This is deprecated and will be disallowed in a future release. select concat('*',v,'*',c,'*',t,'*') as qq from t1 where v='a'; qq *a*a*a* @@ -2714,7 +2723,7 @@ t1 CREATE TABLE `t1` ( `id` tinyint(4) NOT NULL AUTO_INCREMENT, `name` char(30) NOT NULL, PRIMARY KEY (`id`) -) ENGINE=Aria DEFAULT CHARSET=latin1 PAGE_CHECKSUM=1 +) ENGINE=Aria DEFAULT CHARSET=latin1 PAGE_CHECKSUM=0 INSERT INTO t1 (name) VALUES ('dog'); UPDATE t1 SET id=-1 WHERE id=1; INSERT INTO t1 (name) VALUES ('cat'); @@ -2730,3 +2739,76 @@ DROP TABLE t1; # # End of 5.5 tests # +# +# BUG#47444 - --myisam_repair_threads > 1 can result in all index +# cardinalities=1 +# +SET aria_repair_threads=2; +SET aria_sort_buffer_size=8192; +CREATE TABLE t1(a CHAR(255), KEY(a), KEY(a), KEY(a)); +Warnings: +Note 1831 Duplicate index `a_2`. This is deprecated and will be disallowed in a future release. +Note 1831 Duplicate index `a_3`. This is deprecated and will be disallowed in a future release. +INSERT INTO t1 VALUES (0),(1),(2),(3),(4),(5),(6),(7),(8),(9),(0),(1),(2),(3); +REPAIR TABLE t1; +Table Op Msg_type Msg_text +test.t1 repair status OK +SELECT CARDINALITY FROM INFORMATION_SCHEMA.STATISTICS WHERE TABLE_SCHEMA='test' AND TABLE_NAME='t1'; +CARDINALITY +14 +14 +14 +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +DROP TABLE t1; +SET aria_sort_buffer_size=@@global.aria_sort_buffer_size; +SET aria_repair_threads=@@global.aria_repair_threads; +# +# BUG#47073 - valgrind errs, corruption,failed repair of partition, +# low myisam_sort_buffer_size +# +CREATE TABLE t1(a INT, b CHAR(10), KEY(a), KEY(b)); +INSERT INTO t1 VALUES(1,'0'),(2,'0'),(3,'0'),(4,'0'),(5,'0'), +(6,'0'),(7,'0'); +INSERT INTO t1 SELECT a+10,b FROM t1; +INSERT INTO t1 SELECT a+20,b FROM t1; +INSERT INTO t1 SELECT a+40,b FROM t1; +INSERT INTO t1 SELECT a+80,b FROM t1; +INSERT INTO t1 SELECT a+160,b FROM t1; +INSERT INTO t1 SELECT a+320,b FROM t1; +INSERT INTO t1 SELECT a+640,b FROM t1; +INSERT INTO t1 SELECT a+1280,b FROM t1; +INSERT INTO t1 SELECT a+2560,b FROM t1; +INSERT INTO t1 SELECT a+5120,b FROM t1; +SET aria_sort_buffer_size=4096; +REPAIR TABLE t1; +Table Op Msg_type Msg_text +test.t1 repair error aria_sort_buffer_size is too small. X +test.t1 repair error Create index by sort failed +test.t1 repair info Retrying repair with keycache +test.t1 repair status OK +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +SET aria_repair_threads=2; +REPAIR TABLE t1; +Table Op Msg_type Msg_text +test.t1 repair error aria_sort_buffer_size is too small. X +test.t1 repair error Create index by sort failed +test.t1 repair info Retrying repair with keycache +test.t1 repair status OK +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +SET aria_repair_threads=@@global.aria_repair_threads; +SET aria_sort_buffer_size=@@global.aria_sort_buffer_size; +DROP TABLE t1; +CREATE TABLE t1(a INT, b CHAR(10), KEY(a), KEY(b)); +INSERT INTO t1 VALUES(1,'0'),(2,'0'),(3,'0'),(4,'0'),(5,'0'), +(6,'0'),(7,'0'); +flush tables test.t1 for export; +insert into t1 values (8,'0'); +ERROR HY000: Table 't1' was locked with a READ lock and can't be updated +unlock tables; +drop table t1; |