MySQL Forums
Forum List  »  Partitioning

Re: Partition on day of year
Posted by: Brian Wilson
Date: March 04, 2011 10:45AM

First, thanks for your help! Second, a few things to note:

1. I'm using MyISAM (should I not?)
2. The customer_id is almost always going to be = 1
3. Using my current index (customer_id`,`job_date_time`,`printer_name`,`username`) I get results in under 1 second when doing:

SELECT * FROM test_jobs WHERE customer_id = 1 AND job_date_time BETWEEN '2011-01-02 00:00:00' AND '2011-01-02 23:59:59' ORDER BY job_date_time LIMIT 0,25;

But adding the LIKE statements for printer_name and username slow things down to 30 seconds or so. Which seems odd. It's doing the pruning to the right partition...

Options: ReplyQuote


Subject
Views
Written By
Posted
8452
February 28, 2011 07:18PM
2865
February 28, 2011 08:43PM
4067
March 01, 2011 12:53AM
2544
March 01, 2011 10:33PM
2426
March 02, 2011 10:00AM
2029
March 02, 2011 11:16AM
2203
March 03, 2011 09:47PM
2639
March 04, 2011 08:58AM
Re: Partition on day of year
2085
March 04, 2011 10:45AM
2620
March 04, 2011 08:23PM
1807
March 02, 2011 02:58AM


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.