MySQL Forums
Forum List  »  Partitioning

Re: PARTITION BY RANGE ,problem for NULL values
Posted by: Mattias Jonsson
Date: January 20, 2011 07:05AM

When I tried to create the table including the partitioning clause, I got the following warnings:
Warning 1292 Incorrect datetime value: '0000-00-00'
Warning 1292 Incorrect datetime value: '2010-11-31'
Warning 1292 Incorrect datetime value: '2011-11-31'

After correcting the non existent dates (x-11-31 -> x-11-30) it will not break on that error.

Since it is LESS THAN I suggest to use the first in every month instead, currently you have ranges that start with the last in every month and end with the second last day in every month.

And also TO_DAYS(TIMESTAMP_column) is not allowed as partitioning function, I suggest using UNIX_TIMESTAMP(open_date) instead or change the column type to DATETIME.

Read more in the manual, start with:
http://dev.mysql.com/doc/refman/5.5/en/partitioning-limitations-functions.html

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: PARTITION BY RANGE ,problem for NULL values
2397
January 20, 2011 07:05AM


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.