Re: MySQL query with timestamp not using index
Posted by:
Rick James
Date: April 12, 2014 09:49AM
Instead of DESCRIBE, show us SHOW CREATE TABLE, it is more descriptive. In particular, I need to know which ENGINE it is and how the index(es) are declared. (There may be other clues.)
Please provide EXPLAIN PARTITIONS SELECT ... for each SELECT.
How many partitions and rows are in the entire table? In the last 6 days (the selected range)?
Drop "DISTINCT" -- it is unnecessary (even wrong?) when you have that GROUP BY.
It may have done PARTITION PRUNING, but punted on using the INDEX. The above infomation will help me elaborate.
Subject
Views
Written By
Posted
5691
April 11, 2014 11:52AM
1796
April 11, 2014 12:35PM
Re: MySQL query with timestamp not using index
1877
April 12, 2014 09:49AM
2476
April 14, 2014 08:17AM
1834
April 15, 2014 03: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.