Re: Help! Nasty big table efficiency issues with GROUP BY

2004-07-20 Thread Chris Elsworth
On Tue, Jul 20, 2004 at 10:39:00AM +1000, Lachlan Mulcahy wrote: > > Chris, > > Have you checked your following server configurables: > > sort_buffer_size: > - This is the size of the cache created by _each_ thread that requires > ORDER BY or GROUP BY in a query. > If you are doing a lot of lar

RE: Help! Nasty big table efficiency issues with GROUP BY

2004-07-19 Thread Lachlan Mulcahy
Chris, Have you checked your following server configurables: sort_buffer_size: - This is the size of the cache created by _each_ thread that requires ORDER BY or GROUP BY in a query. If you are doing a lot of large ordered queries you will need to increase this value otherwise MySQL will use _d

Re: Help! Nasty big table efficiency issues with GROUP BY

2004-07-19 Thread SGreen
Have you tried moving the "GroupID not IN ()" into your JOIN clause? SELECT * FROM News JOIN FileGroup ON News.FileID = FileGroup.FileID AND FileGroup.GroupID NOT IN (638) WHERE News.Category = 7 GROUP BY News.FileID ORDER BY News.Date DESC LIMIT 100 I think, though, that beca