Details
-
Task
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
Extend current partition truncation to better support rolling dates in tables.
CREATE TABLE members ( |
firstname VARCHAR(25) NOT NULL, |
lastname VARCHAR(25) NOT NULL, |
username VARCHAR(16) NOT NULL, |
joined DATETIME NOT NULL |
)
|
PARTITION BY HASH(TO_DAYS(joined)) |
PARTITIONS 7;
|
ALTER TABLE t1 TRUNCATE PARTITION WHERE joined='2014-01-01' |
The effect would be that the partition that would be mapped from the value '2014-01-01' would be truncated.