Re:Ask HN: I built a site that just went ridiculously viral....
by cd34 on Thursday December 30, 2010 @03:07AM
(#2051686)
MySQL's query plan is odd at times. What does an explain look like on that query? If any portion of the query, including subselects isn't able to use an index, it will report it. You can try to force indicies with USE INDEX/FORCE INDEX which can sometimes help.
[ Parent
| on HN ]
Re:Ask HN: I built a site that just went ridiculously viral....
by cd34 on Thursday December 30, 2010 @10:28AM
(#2052392)
Re:Ask HN: I built a site that just went ridiculously viral....
by Luyt on Thursday December 30, 2010 @05:59AM
(#2051910)
Ah, I was having trouble with another slow query; however, the EXPLAIN showed that the correct indices were used. I managed to speed it up by restricting the size of the inner SELECT with some extra constraints. From 4 seconds downto 0.1 seconds!