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
7312
February 28, 2011 07:18PM
2442
February 28, 2011 08:43PM
3627
March 01, 2011 12:53AM
2163
March 01, 2011 10:33PM
2038
March 02, 2011 10:00AM
1671
March 02, 2011 11:16AM
1787
March 03, 2011 09:47PM
2220
March 04, 2011 08:58AM
Re: Partition on day of year
1777
March 04, 2011 10:45AM
2221
March 04, 2011 08:23PM
1481
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.