MySQL Forums
Forum List  »  Partitioning

Re: Partitioning by hour
Posted by: Alejandro Boldt
Date: September 17, 2009 06:31AM

Rick James Wrote:
-------------------------------------------------------
> Correction: HOUR() is available as of 5.1.12:
> http://dev.mysql.com/doc/refman/5.1/en/partitionin
> g-limitations-functions.html

Thanks! Yes, HOUR() allows me to split the table in partitions by hour (the benefit of this is that I have daily tables with about 50 gigs of data, everyday, and it would help me with partition pruning).

However, although the table is in fact created with hourly partitions, I get no benefit out of pruning.

http://dev.mysql.com/doc/refman/5.1/en/partitioning-pruning.html says Pruning can also be applied for tables partitioned on a DATE or DATETIME column when the partitioning expression uses the YEAR() or TO_DAYS() function.

So I was wondering if there was some kind of workaround, besides adding an hour INT column as you suggested.

Options: ReplyQuote


Subject
Views
Written By
Posted
3004
September 11, 2009 01:32PM
2223
September 12, 2009 03:12PM
2082
September 12, 2009 09:31PM
Re: Partitioning by hour
2721
September 17, 2009 06:31AM
2132
September 17, 2009 08:45AM
2170
September 17, 2009 09:50AM
2149
September 21, 2009 03:55AM


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.