It helped me. Especially the part about tricking MySQL to not use an index, without using USE INDEX or FORCE INDEX (which can be very bad if you have a dynamic query or your tables change/grow, something they usually do).
http://code.openark.org/blog/mysql/7-ways-to-convince-mysql-to-use-the-right-index
Note that Solution #7: Make MySQL think the problem is harder than it really is can also be applied to GROUP BY. e.g.
GROUP BY id, type, level
No comments:
Post a Comment