Force mysql to use index a certain way -
i've found when running queries against our mysql db (5.5.27) when optimizer chooses utilize use index range responds quickly, when chooses ref_or_null takes longer.
is there way forcefulness index utilize range?
if you're sure optimizer not using indexes properly, can seek utilize index hints.
select * table1 utilize index (col1_index,col2_index) col1=1 , col2=2 , col3=3;
documentation
mysql
No comments:
Post a Comment