MySQL Forums
Forum List  »  Performance

Re: MySQL 5.6 update doubled IOs
Posted by: Øystein Grøvlen
Date: April 02, 2013 12:30AM

Hi Christian,

What happens if you before running this query do:

set optimizer_switch='mrr=off';

MRR will give overhead to your query since it will buffer several keys before doing table look-up. In your case, due to LIMIT 1 clause, you only need to look up the first key since, given the index that is used, it will be the one with the lowest ip_end and the only one that satisfy the ip_begin condition (assuming non-overlapping intervals). Because of the latter, you will not benefit from Index Condition Pushdown either, and might as well do:

set optimizer_switch='index_condition_pushdown=off':

Hope this helps,

Øystein Grøvlen,
Senior Principal Software Engineer,
MySQL Group, Oracle,
Trondheim, Norway

Options: ReplyQuote


Subject
Views
Written By
Posted
1260
March 20, 2013 08:52AM
1170
March 27, 2013 11:44PM
1198
March 28, 2013 07:49PM
1126
April 02, 2013 12:20AM
Re: MySQL 5.6 update doubled IOs
1188
April 02, 2013 12:30AM
1173
April 02, 2013 09:57PM
1146
April 10, 2013 08:31AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.