Details
-
Task
-
Status: Open (View Workflow)
-
Minor
-
Resolution: Unresolved
-
None
-
None
Description
Implement merging of multiple history partitions by the syntax:
create or replace table t1 (x int) with system versioning |
partition by system_time partitions 3; |
alter table t1 reorganize partition p0, p1 into (partition p0 history); |
Consider implementing splitting into multiple history partitions:
create or replace table t1 (x int) with system versioning |
partition by system_time; |
alter table t1 reorganize partition p0 into (partition p0 history, partition p1 history); |
Splitting distributes rows equally between specified partitions.
For INTERVAL:
Merging and splitting is forbidden.
For LIMIT:
Merging is forbidden when LIMIT is overflown.
Currently splitting and merging fail with error:
ERROR 1510 (HY000): REORGANIZE PARTITION can only be used to reorganize partitions not to change their numbers
|
Attachments
Issue Links
- relates to
-
MDEV-17554 Auto-create history partitions for system-versioned tables
-
- Closed
-
-
MDEV-19903 Setup default partitions for system versioning
-
- Closed
-
I don't understand.
Does it mean that p1 is not used at all? Why is it allowed then?
With INTERVAL one cannot split or reorganize partitions, it'll break the interval logic.
So LIMIT seems to be the only use case when such reorganization could make sense.