...

View Full Version : group by / order by/ filesort / temporary



BubikolRamios
11-24-2011, 05:43 PM
I know for this for a while, but dont know for solution.

Is there any way around that:



select ..
group by ..
order by ..

---> 1,139 sec, explain: Using temporary; Using filesort



select ..
group by ..

---> 0,045 sec, explain:

BubikolRamios
11-24-2011, 05:59 PM
Hmm, tested. Vrapping all into select & putting order by into outer sql does immediate trick (but then result is wrong)
I don't like that doh, any other thought ?

BubikolRamios
11-24-2011, 08:41 PM
see sample:
http://shrani.si/t/d/Pk/1KAeHn3n/tmp.jpg (http://shrani.si/?d/Pk/1KAeHn3n/tmp.jpg)



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum