mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
Made the optimizer switch for index condition pushdown set to 'on' by default.
This commit is contained in:
@ -778,7 +778,7 @@ create table t1 (a int primary key,b int, c int, d int, e int, f int, g int, h
|
||||
insert into t1 values (1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1);
|
||||
explain select * from t1 where a > 0 and a < 50;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 range PRIMARY PRIMARY 4 NULL # Using where
|
||||
1 SIMPLE t1 range PRIMARY PRIMARY 4 NULL # Using index condition
|
||||
drop table t1;
|
||||
create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=innodb;
|
||||
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
|
||||
@ -1219,7 +1219,7 @@ count(*)
|
||||
623
|
||||
explain select * from t1 where c between 1 and 2500;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 range c c 5 NULL # Using where
|
||||
1 SIMPLE t1 range c c 5 NULL # Using index condition
|
||||
update t1 set c=a;
|
||||
explain select * from t1 where c between 1 and 2500;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
@ -1914,7 +1914,7 @@ qq
|
||||
*a *a*a *
|
||||
explain select * from t1 where v='a';
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 ref v,v_2 # 13 const # Using where
|
||||
1 SIMPLE t1 ref v,v_2 # 13 const # Using index condition
|
||||
select v,count(*) from t1 group by v limit 10;
|
||||
v count(*)
|
||||
a 1
|
||||
@ -2090,7 +2090,7 @@ id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 ref v v 303 const # Using where; Using index
|
||||
explain select * from t1 where v='a';
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 SIMPLE t1 ref v v 303 const # Using where
|
||||
1 SIMPLE t1 ref v v 303 const # Using index condition
|
||||
select v,count(*) from t1 group by v limit 10;
|
||||
v count(*)
|
||||
a 1
|
||||
|
Reference in New Issue
Block a user