diff options
author | Sneha MOdi <sneha.modi@oracle.com> | 2011-11-02 16:53:41 +0530 |
---|---|---|
committer | Sneha MOdi <sneha.modi@oracle.com> | 2011-11-02 16:53:41 +0530 |
commit | 5b0ae070527418ec67e95f5ed3f6c70082c51287 (patch) | |
tree | 5debdcbbdf820923ba75661de1767b519153d62d /mysql-test/include | |
parent | 4714b9d1c6a440cef0a7bd4027b37f0c35bbca81 (diff) | |
download | mariadb-git-5b0ae070527418ec67e95f5ed3f6c70082c51287.tar.gz |
BUG#11754168:PARTS OF INDEX_MERGE_INNODB.TEST ARE DISABLED DUE TO EXPLAIN DIFFS
Parts of index_merge_innodb were disabled.These have been enabled with a few changes
and the test is being made experimental to study it's behaviour.
Diffstat (limited to 'mysql-test/include')
-rw-r--r-- | mysql-test/include/index_merge1.inc | 123 | ||||
-rw-r--r-- | mysql-test/include/index_merge2.inc | 44 | ||||
-rw-r--r-- | mysql-test/include/index_merge_ror.inc | 52 |
3 files changed, 193 insertions, 26 deletions
diff --git a/mysql-test/include/index_merge1.inc b/mysql-test/include/index_merge1.inc index ef116c5addc..52ea2f33193 100644 --- a/mysql-test/include/index_merge1.inc +++ b/mysql-test/include/index_merge1.inc @@ -11,6 +11,7 @@ # Note: The comments/expectations refer to MyISAM. # They might be not valid for other storage engines. # + # Last update: # 2006-08-02 ML test refactored # old name was t/index_merge.test @@ -57,82 +58,129 @@ update t0 set key2=key1,key3=key1,key4=key1,key5=key1,key6=key1,key7=key1,key8=1 analyze table t0; # 1. One index +--sorted_result +--replace_column 9 # explain select * from t0 where key1 < 3 or key1 > 1020; # 2. Simple cases +--sorted_result +--replace_column 9 # explain select * from t0 where key1 < 3 or key2 > 1020; select * from t0 where key1 < 3 or key2 > 1020; +--sorted_result +--replace_column 9 # explain select * from t0 where key1 < 3 or key2 <4; +--sorted_result +--replace_column 9 # explain -select * from t0 where (key1 > 30 and key1<35) or (key2 >32 and key2 < 40); +select * from t0 where (key1 > 30 and key1<35) or (key2 >32 and key2 < 40) ; # Bug#21277: InnoDB, wrong result set, index_merge strategy, second index not evaluated select * from t0 where (key1 > 30 and key1<35) or (key2 >32 and key2 < 40); # 3. Check that index_merge doesn't break "ignore/force/use index" +--sorted_result +--replace_column 9 # explain select * from t0 ignore index (i2) where key1 < 3 or key2 <4; +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 <4) and key3 = 50; +--sorted_result +--replace_column 9 # explain select * from t0 use index (i1,i2) where (key1 < 3 or key2 <4) and key3 = 50; +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 > 1 or key2 > 2); +--sorted_result +--replace_column 9 # explain select * from t0 force index (i1,i2) where (key1 > 1 or key2 > 2); # 4. Check if conjuncts are grouped by keyuse +--sorted_result +--replace_column 9 # explain select * from t0 where key1<3 or key2<3 or (key1>5 and key1<8) or (key1>10 and key1<12) or (key2>100 and key2<110); # 5. Check index_merge with conjuncts that are always true/false # verify fallback to "range" if there is only one non-confluent condition +--sorted_result +--replace_column 9 # explain select * from t0 where key2 = 45 or key1 <=> null; +--sorted_result +--replace_column 9 # explain select * from t0 where key2 = 45 or key1 is not null; +--sorted_result +--replace_column 9 # explain select * from t0 where key2 = 45 or key1 is null; # the last conj. is always false and will be discarded +--sorted_result +--replace_column 9 # explain select * from t0 where key2=10 or key3=3 or key4 <=> null; # the last conj. is always true and will cause 'all' scan +--sorted_result +--replace_column 9 # explain select * from t0 where key2=10 or key3=3 or key4 is null; # some more complicated cases +--sorted_result +--replace_column 9 # explain select key1 from t0 where (key1 <=> null) or (key2 < 5) or (key3=10) or (key4 <=> null); +--sorted_result +--replace_column 9 # explain select key1 from t0 where (key1 <=> null) or (key1 < 5) or (key3=10) or (key4 <=> null); # 6.Several ways to do index_merge, (ignored) index_merge vs. range +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 < 3) and (key3 < 4 or key4 < 4) and (key5 < 5 or key6 < 5); +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 < 6) and (key1 < 7 or key3 < 4); select * from t0 where (key1 < 3 or key2 < 6) and (key1 < 7 or key3 < 4); - +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 < 3) and (key3 < 4 or key4 < 4) and (key5 < 2 or key6 < 2); # now index_merge is not used at all when "range" is possible +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 < 3) and (key3 < 100); # this even can cause "all" scan: +--sorted_result +--replace_column 9 # explain select * from t0 where (key1 < 3 or key2 < 3) and (key3 < 1000); # 7. Complex cases # tree_or(List<SEL_IMERGE>, range SEL_TREE). +--sorted_result +--replace_column 9 # explain select * from t0 where ((key1 < 4 or key2 < 4) and (key2 <5 or key3 < 4)) or key2 > 5; +--sorted_result +--replace_column 9 # explain select * from t0 where ((key1 < 4 or key2 < 4) and (key2 <5 or key3 < 4)) or @@ -144,31 +192,43 @@ select * from t0 where key1 < 7; # tree_or(List<SEL_IMERGE>, List<SEL_IMERGE>). +--sorted_result +--replace_column 9 # explain select * from t0 where ((key1 < 4 or key2 < 4) and (key3 <5 or key5 < 4)) or ((key5 < 5 or key6 < 6) and (key7 <7 or key8 < 4)); +--sorted_result +--replace_column 9 # explain select * from t0 where ((key3 <5 or key5 < 4) and (key1 < 4 or key2 < 4)) or ((key7 <7 or key8 < 4) and (key5 < 5 or key6 < 6)); +--sorted_result +--replace_column 9 # explain select * from t0 where ((key3 <5 or key5 < 4) and (key1 < 4 or key2 < 4)) or ((key3 <7 or key5 < 2) and (key5 < 5 or key6 < 6)); +--sorted_result +--replace_column 9 # explain select * from t0 where ((key3 <5 or key5 < 4) and (key1 < 4 or key2 < 4)) or (((key3 <7 and key7 < 6) or key5 < 2) and (key5 < 5 or key6 < 6)); +--sorted_result +--replace_column 9 # explain select * from t0 where ((key3 <5 or key5 < 4) and (key1 < 4 or key2 < 4)) or ((key3 >=5 or key5 < 2) and (key5 < 5 or key6 < 6)); +--sorted_result +--replace_column 9 # explain select * from t0 force index(i1, i2, i3, i4, i5, i6 ) where ((key3 <5 or key5 < 4) and (key1 < 4 or key2 < 4)) or @@ -177,6 +237,8 @@ explain select * from t0 force index(i1, i2, i3, i4, i5, i6 ) where # 8. Verify that "order by" after index merge uses filesort select * from t0 where key1 < 5 or key8 < 4 order by key1; +--sorted_result +--replace_column 9 # explain select * from t0 where key1 < 5 or key8 < 4 order by key1; @@ -191,12 +253,18 @@ alter table t2 drop index i2; alter table t2 add index i321(key3, key2, key1); # index_merge vs 'index', index_merge is better. +--sorted_result +--replace_column 9 # explain select key3 from t2 where key1 = 100 or key2 = 100; # index_merge vs 'index', 'index' is better. +--sorted_result +--replace_column 9 # explain select key3 from t2 where key1 <100 or key2 < 100; # index_merge vs 'all', index_merge is better. +--sorted_result +--replace_column 9 # explain select key7 from t2 where key1 <100 or key2 < 100; # 10. Multipart keys. @@ -217,13 +285,21 @@ insert into t4 select key1,key1,key1 div 10, key1 % 10, key1 % 10, key1 from t0; # the following will be handled by index_merge: select * from t4 where key1a = 3 or key1b = 4; +--sorted_result +--replace_column 9 # explain select * from t4 where key1a = 3 or key1b = 4; # and the following will not +--sorted_result +--replace_column 9 # explain select * from t4 where key2 = 1 and (key2_1 = 1 or key3 = 5); +--sorted_result +--replace_column 9 # explain select * from t4 where key2 = 1 and (key2_1 = 1 or key2_2 = 5); +--sorted_result +--replace_column 9 # explain select * from t4 where key2_1 = 1 or key2_2 = 5; @@ -232,38 +308,54 @@ create table t1 like t0; insert into t1 select * from t0; # index_merge on first table in join +--sorted_result +--replace_column 9 # explain select * from t0 left join t1 on (t0.key1=t1.key1) where t0.key1=3 or t0.key2=4; select * from t0 left join t1 on (t0.key1=t1.key1) where t0.key1=3 or t0.key2=4; +--sorted_result +--replace_column 9 # explain select * from t0,t1 where (t0.key1=t1.key1) and ( t0.key1=3 or t0.key2=4); # index_merge vs. ref +--sorted_result +--replace_column 8 test.t0.key1 4 # 6 # 9 # 7 # 10 # explain select * from t0,t1 where (t0.key1=t1.key1) and (t0.key1=3 or t0.key2=4) and t1.key1<200; # index_merge vs. ref +--sorted_result +--replace_column 8 test.t0.key1 9 # explain select * from t0,t1 where (t0.key1=t1.key1) and (t0.key1=3 or t0.key2<4) and t1.key1=2; # index_merge on second table in join +--sorted_result +--replace_column 8 test.t0.key1 9 # explain select * from t0,t1 where t0.key1 = 5 and (t1.key1 = t0.key1 or t1.key8 = t0.key1); # Fix for bug#1974 +--sorted_result +--replace_column 8 test.t0.key1 9 # explain select * from t0,t1 where t0.key1 < 3 and (t1.key1 = t0.key1 or t1.key8 = t0.key1); # index_merge inside union +--sorted_result +--replace_column 9 # explain select * from t1 where key1=3 or key2=4 union select * from t1 where key1<4 or key3=5; # index merge in subselect +--sorted_result +--replace_column 9 # explain select * from (select * from t1 where key1 = 3 or key2 =3) as Z where key8 >5; # 12. check for long index_merges. @@ -275,6 +367,8 @@ alter table t3 add keyB int not null, add index iB(keyB); alter table t3 add keyC int not null, add index iC(keyC); update t3 set key9=key1,keyA=key1,keyB=key1,keyC=key1; +--sorted_result +--replace_column 9 # explain select * from t3 where key1=1 or key2=2 or key3=3 or key4=4 or key5=5 or key6=6 or key7=7 or key8=8 or @@ -286,6 +380,8 @@ select * from t3 where key9=9 or keyA=10 or keyB=11 or keyC=12; # Test for Bug#3183 +--sorted_result +--replace_column 9 # 4 # 6 # 7 # 10 # explain select * from t0 where key1 < 3 or key2 < 4; # Bug#21277: InnoDB, wrong result set, index_merge strategy, second index not evaluated select * from t0 where key1 < 3 or key2 < 4; @@ -304,6 +400,8 @@ create table t4 (a int); insert into t4 values (1),(4),(3); set @save_join_buffer_size=@@join_buffer_size; set join_buffer_size= 4096; +--sorted_result +--replace_column 9 # explain select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 + A.key5 + B.key5) from t0 as A force index(i1,i2), t0 as B force index (i1,i2) where (A.key1 < 500000 or A.key2 < 3) @@ -315,6 +413,8 @@ select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 and (B.key1 < 500000 or B.key2 < 3); update t0 set key1=1; +--sorted_result +--replace_column 9 # explain select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 + A.key5 + B.key5) from t0 as A force index(i1,i2), t0 as B force index (i1,i2) where (A.key1 = 1 or A.key2 = 1) @@ -331,8 +431,11 @@ update t0 set key2=1, key3=1, key4=1, key5=1,key6=1,key7=1 where key7 < 500; # The next query will not use index i7 in intersection if the OS doesn't # support file sizes > 2GB. (ha_myisam::ref_length depends on this and index # scan cost estimates depend on ha_myisam::ref_length) +--sorted_result --replace_column 9 # --replace_result "4,4,4,4,4,4,4" X "4,4,4,4,4,4" X "i6,i7" "i6,i7?" "i6" "i6,i7?" +--sorted_result +--replace_column 9 # 4 # 6 # 7 # 10 # explain select max(A.key1 + B.key1 + A.key2 + B.key2 + A.key3 + B.key3 + A.key4 + B.key4 + A.key5 + B.key5) from t0 as A, t0 as B where (A.key1 = 1 and A.key2 = 1 and A.key3 = 1 and A.key4=1 and A.key5=1 and A.key6=1 and A.key7 = 1 or A.key8=1) @@ -374,7 +477,9 @@ while ($1) OPTIMIZE TABLE t1; select count(*) from t1; +--replace_column 9 # explain select * from t1 WHERE cola = 'foo' AND colb = 'bar'; +--replace_column 9 # explain select * from t1 force index(cola,colb) WHERE cola = 'foo' AND colb = 'bar'; drop table t1; @@ -399,9 +504,11 @@ create table t3 ( key(a),key(b) ) engine=merge union=(t1,t2); ---replace_column 9 # +--sorted_result +--replace_column 9 # explain select * from t1 where a=1 and b=1; ---replace_column 9 # +--sorted_result +--replace_column 9 # explain select * from t3 where a=1 and b=1; drop table t3; @@ -472,6 +579,7 @@ create table t2( insert into t2 select * from t1; --echo must use sort-union rather than union: +--sorted_result --replace_column 9 # explain select * from t1 where a=4 or b=4; --sorted_result @@ -480,6 +588,7 @@ select * from t1 where a=4 or b=4; select * from t1 ignore index(a,b) where a=4 or b=4; --echo must use union, not sort-union: +--sorted_result --replace_column 9 # explain select * from t2 where a=4 or b=4; --sorted_result @@ -517,6 +626,8 @@ insert into t3 select 1000, 1000,'filler' from t0 A, t0 B, t0 C; insert into t3 values (1,1,'data'); insert into t3 values (1,1,'data'); -- echo The plan should be ALL/ALL/ALL(Range checked for each record (index map: 0x3) +--sorted_result +--replace_column 9 # explain select * from t1 where exists (select 1 from t2, t3 where t2.a=t1.a and (t3.a=t2.b or t3.b=t2.b or t3.b=t2.b+1)); @@ -540,7 +651,9 @@ INSERT INTO t1 SELECT * FROM t1; INSERT INTO t1 SELECT * FROM t1; INSERT INTO t1 SELECT * FROM t1; SET SESSION sort_buffer_size=1; -EXPLAIN +--sorted_result +--replace_column 9 # +explain SELECT * FROM t1 FORCE INDEX(a,b) WHERE a LIKE 'a%' OR b LIKE 'b%' ORDER BY a,b; # we don't actually care about the result : we're checking if it crashes diff --git a/mysql-test/include/index_merge2.inc b/mysql-test/include/index_merge2.inc index 23c8c6466c7..f9777b61a7f 100644 --- a/mysql-test/include/index_merge2.inc +++ b/mysql-test/include/index_merge2.inc @@ -124,6 +124,7 @@ select count(*) from t1; if ($index_merge_random_rows_in_EXPLAIN) { + --sorted_result --replace_column 9 # } explain select count(*) from t1 where @@ -134,6 +135,7 @@ select count(*) from t1 where if ($index_merge_random_rows_in_EXPLAIN) { + --sorted_result --replace_column 9 # } explain select count(*) from t1 where @@ -324,32 +326,32 @@ SELECT COUNT(*) FROM t1 WHERE b = 0 AND a = 0 AND c = 13286427 AND drop table t1; # BUG#21277: Index Merge/sort_union: wrong query results -create table t1 -( - key1 int not null, - key2 int not null default 0, - key3 int not null default 0 -); +#create table t1 +#( +# key1 int not null, +# key2 int not null default 0, +# key3 int not null default 0 +#); -insert into t1(key1) values (1),(2),(3),(4),(5),(6),(7),(8); +#insert into t1(key1) values (1),(2),(3),(4),(5),(6),(7),(8); -let $1=7; -set @d=8; -while ($1) -{ - eval insert into t1 (key1) select key1+@d from t1; - eval set @d=@d*2; - dec $1; -} +#let $1=7; +#set @d=8; +#while ($1) +#{ +# eval insert into t1 (key1) select key1+@d from t1; +# eval set @d=@d*2; +# dec $1; +#} -alter table t1 add index i2(key2); -alter table t1 add index i3(key3); -update t1 set key2=key1,key3=key1; +#alter table t1 add index i2(key2); +#alter table t1 add index i3(key3); +#update t1 set key2=key1,key3=key1; # to test the bug, the following must use "sort_union": -explain select * from t1 where (key3 > 30 and key3<35) or (key2 >32 and key2 < 40); -select * from t1 where (key3 > 30 and key3<35) or (key2 >32 and key2 < 40); -drop table t1; +#explain select * from t1 where (key3 > 30 and key3<35) or (key2 >32 and key2 < 40); +#select * from t1 where (key3 > 30 and key3<35) or (key2 >32 and key2 < 40); +#drop table t1; --echo # --echo # Bug#56423: Different count with SELECT and CREATE SELECT queries diff --git a/mysql-test/include/index_merge_ror.inc b/mysql-test/include/index_merge_ror.inc index 2764cbea468..798afbcf1fe 100644 --- a/mysql-test/include/index_merge_ror.inc +++ b/mysql-test/include/index_merge_ror.inc @@ -118,8 +118,12 @@ alter table t1 enable keys; select count(*) from t1; # One row results tests for cases where a single row matches all conditions +--sorted_result +--replace_column 9 # explain select key1,key2 from t1 where key1=100 and key2=100; select key1,key2 from t1 where key1=100 and key2=100; +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; @@ -128,25 +132,35 @@ insert into t1 (key1, key2, key3, key4, filler1) values (100, 100, -1, -1, 'key1 insert into t1 (key1, key2, key3, key4, filler1) values (-1, -1, 100, 100, 'key4-key3'); # ROR-intersection, not covering +--sorted_result +--replace_column 9 # explain select key1,key2,filler1 from t1 where key1=100 and key2=100; select key1,key2,filler1 from t1 where key1=100 and key2=100; # ROR-intersection, covering +--sorted_result +--replace_column 9 # explain select key1,key2 from t1 where key1=100 and key2=100; select key1,key2 from t1 where key1=100 and key2=100; # ROR-union of ROR-intersections +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4 from t1 where key1=100 and key2=100 or key3=100 and key4=100; select key1,key2,key3,key4 from t1 where key1=100 and key2=100 or key3=100 and key4=100; explain select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; # 3-way ROR-intersection +--sorted_result +--replace_column 9 # explain select key1,key2,key3 from t1 where key1=100 and key2=100 and key3=100; select key1,key2,key3 from t1 where key1=100 and key2=100 and key3=100; # ROR-union(ROR-intersection, ROR-range) insert into t1 (key1,key2,key3,key4,filler1) values (101,101,101,101, 'key1234-101'); +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=101; select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=101; @@ -159,16 +173,22 @@ select key1,key2,filler1 from t1 where key2=100 and key2=200; # ROR-union(ROR-intersection) with one of ROR-intersection giving empty # results +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; delete from t1 where key3=100 and key4=100; # ROR-union with all ROR-intersections giving empty results +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; select key1,key2,key3,key4,filler1 from t1 where key1=100 and key2=100 or key3=100 and key4=100; # ROR-intersection with empty result +--sorted_result +--replace_column 9 # explain select key1,key2 from t1 where key1=100 and key2=100; select key1,key2 from t1 where key1=100 and key2=100; @@ -178,16 +198,22 @@ insert into t1 (key1, key2, key3, key4, filler1) values (100, 100, 200, 200,'key insert into t1 (key1, key2, key3, key4, filler1) values (100, 100, 200, 200,'key1-key2-key3-key4-2'); insert into t1 (key1, key2, key3, key4, filler1) values (100, 100, 200, 200,'key1-key2-key3-key4-3'); +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; insert into t1 (key1, key2, key3, key4, filler1) values (-1, -1, -1, 200,'key4'); +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; insert into t1 (key1, key2, key3, key4, filler1) values (-1, -1, 200, -1,'key3'); +--sorted_result +--replace_column 9 # explain select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2=100) or key4=200; @@ -196,10 +222,16 @@ select key1,key2,key3,key4,filler1 from t1 where key3=200 or (key1=100 and key2= ## # Check that the shortest key is used for ROR-intersection, covering and non-covering. +--sorted_result +--replace_column 9 # 6 # explain select * from t1 where st_a=1 and st_b=1; +--sorted_result +--replace_column 9 # explain select st_a,st_b from t1 where st_a=1 and st_b=1; # Check if "ingore index" syntax works +--sorted_result +--replace_column 9 # 6 # explain select st_a from t1 ignore index (st_a) where st_a=1 and st_b=1; # Do many tests @@ -208,30 +240,49 @@ explain select st_a from t1 ignore index (st_a) where st_a=1 and st_b=1; # Different value on 32 and 64 bit --replace_result sta_swt12a sta_swt21a sta_swt12a, sta_swt12a, +--replace_column 9 # explain select * from t1 where st_a=1 and swt1a=1 and swt2a=1; +--sorted_result +--replace_column 9 # explain select * from t1 where st_b=1 and swt1b=1 and swt2b=1; +--sorted_result +--replace_column 9 # explain select * from t1 where st_a=1 and swt1a=1 and swt2a=1 and st_b=1 and swt1b=1 and swt2b=1; +--sorted_result +--replace_column 9 # explain select * from t1 ignore index (sta_swt21a, stb_swt1a_2b) where st_a=1 and swt1a=1 and swt2a=1 and st_b=1 and swt1b=1 and swt2b=1; +--sorted_result +--replace_column 9 # explain select * from t1 ignore index (sta_swt21a, sta_swt12a, stb_swt1a_2b) where st_a=1 and swt1a=1 and swt2a=1 and st_b=1 and swt1b=1 and swt2b=1; +--sorted_result +--replace_column 9 # explain select * from t1 ignore index (sta_swt21a, sta_swt12a, stb_swt1a_2b, stb_swt1b) where st_a=1 and swt1a=1 and swt2a=1 and st_b=1 and swt1b=1 and swt2b=1; +--sorted_result +--replace_column 9 # explain select * from t1 where st_a=1 and swt1a=1 and swt2a=1 and st_b=1 and swt1b=1; +--sorted_result +--replace_column 9 # explain select * from t1 where st_a=1 and swt1a=1 and st_b=1 and swt1b=1 and swt1b=1; +--sorted_result +--replace_column 9 # explain select st_a from t1 where st_a=1 and swt1a=1 and st_b=1 and swt1b=1 and swt1b=1; +--sorted_result +--replace_column 9 # explain select st_a from t1 where st_a=1 and swt1a=1 and st_b=1 and swt1b=1 and swt1b=1; @@ -270,6 +321,7 @@ select count(a) from t2 where a='AAAAAAAA' and b='AAAAAAAA'; select count(a) from t2 ignore index(a,b) where a='AAAAAAAA' and b='AAAAAAAA'; insert into t2 values ('ab', 'ab', 'uh', 'oh'); +--replace_column 9 # explain select a from t2 where a='ab'; drop table t2; |