108
108
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
109
109
explain select * from t1 where btn like "q%";
110
110
select * from t1 where btn like "q%";
111
alter table t1 add column new_col char(1) not null, add key using HASH (btn,new_col), drop key btn;
111
alter table t1 add column new_col char(1) default "Y" not null, add key using HASH (btn,new_col), drop key btn;
112
112
update t1 set new_col=left(btn,1);
113
113
explain select * from t1 where btn="a";
114
114
explain select * from t1 where btn="a" and new_col="a";