MySQL Forums
Forum List  »  Partitioning

Re: Auto Partitioning using unix time
Posted by: Mikael Ronström
Date: February 11, 2006 02:55AM

To use the partition function PARTITION BY RANGE/LIST (TO_DAYS(a_date_field))
will have a very good effect on the optimizer since it will then know that it can apply
range optimisations.

A new feature recently added to 5.1 is the ability to create SQL events. So you could
define an event that on a daily basis adds a new partition and if you want other
regular activities for dropping and reorganizing your partitions that can be done as well.

Check the new devzone article on this:
http://dev.mysql.com/tech-resources/articles/event-feature.html

Rgrds Mikael

Jason Lewis wrote:
> Partitioning by day was what I was looking for
> initially, and I could manually do it a couple of
> ways. Since all my dates are already Unix time, i
> figured that would make it easy on me during
> INSERTS.

Mikael Ronstrom
Senior Software Architect, MySQL AB
My blog: http://mikaelronstrom.blogspot.com

Options: ReplyQuote


Subject
Views
Written By
Posted
7407
January 17, 2006 03:14PM
3408
January 30, 2006 07:09AM
2892
January 31, 2006 08:06AM
2619
February 10, 2006 11:22PM
Re: Auto Partitioning using unix time
2718
February 11, 2006 02:55AM
2685
March 07, 2006 08:00AM


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.