MySQL Forums
Forum List  »  Optimizer & Parser

Using FileSort
Posted by: Clement Ho
Date: September 10, 2007 05:21PM

I have 2 query, the 1st one require Using filesort and the next is not. The only different is "SQL_CALC_FOUND_ROWS" why would that key word cause "using filesort"?

1.
explain Select SQL_CALC_FOUND_ROWS SID,StoryTime,Service,Symbols,Category,Headline from tbl_mainNews use index(idx_StoryTime) where (StoryTime <= '2007-9-11' and StoryTime >= '2007-1-10') order by storytime DESC limit 0,50

2.
explain Select SID,StoryTime,Service,Symbols,Category,Headline from tbl_mainNews use index(idx_StoryTime) where (StoryTime <= '2007-9-11' and StoryTime >= '2007-1-10') order by storytime DESC limit 0,50

Options: ReplyQuote


Subject
Views
Written By
Posted
Using FileSort
4352
September 10, 2007 05:21PM


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.