EXPLAIN
SELECT * FROM test_askcomment WHERE cid IN(1,2,3) ORDER BY dateline DESC;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE test_askcomment ALL PRIMARY NULL NULL NULL 3 Using where; Using filesort
EXPLAIN SELECT * FROM test_askcomment WHERE cid IN(1,2,3) ORDER BY dateline DESC; id select_type
Share
try to index your coloumns on which you are using where clause or selecting the coloumns