Background
Range partitioning: Multiple rows with column values in an ordered, continuous, and non-overlapping range are assigned to a partition. For details, see Set partitioning rules.
Partitioning Plan: When inserting data in a range-partitioned table, if the inserted data exceeds the upper limit value of the current partition table, the data will not be inserted and an error will be returned. Partitioning plan is an extension function specially for range partitioning. ODC supports automatic management of range-partitioned table according to the partitioning strategy set by the user. Users do not need to manually create new partitions to facilitate the maintenance of range-partitioned table.
This topic describes how to use a partitioning plan in the OceanBase Development Center (ODC) console, including performing automatic management on created and dropped table partitions.
Create a partitioning plan
Notice
The Partitioning Plan of ODC V4.0.0 only supports the Range partition table of the Timestamp field type and the Range Columns partition table of the Date field type. When Range/Range Columns partition tables of other field types exist, the creation of partitioning plan of this type will be skipped and a warning log will be recorded.
Log on to the ODC console, and click the name of the target connection to go to the corresponding database object management page.
In the top navigation pane, choose Tool > Partition Plan to display the Create a partition plan panel.

In the Create a partition plan panel, specify the following information.

Parameter Description Connection The connection to which the partitioning plan belongs. The default value is the current connection. Partition policy The information about the partitioning strategy. Search for and select a range-partitioned table in the database and edit its partitioning strategy. - You can select Only tables that are not set are displayed on the right side of Partition policy to display only tables with no partitioning strategies.
- You can also select multiple range-partitioned tables and configure a partitioning strategy for them at a time.
- In the Partitioning Strategy column, click the edit icon and then you can edit the number of partitions to create, partitioning interval, retention period, and naming rules.
- Number of Partitions: set the number of partitions to pre-create.
- Partition Interval: pre-create the corresponding number of partitions based on the time interval, unit: day/month/year.
- Retention Period: the created partition is automatically cleared after the retention period expires, unit: day/month/year.
Example: The number of partitions is 1, the partition interval is 1 month, and the retention period is 1 month, which means that 1 partition is pre-created for the current table, and 1 partition will be created every 1 month, and the created partition will be cleaned up automatically after 1 month.

Remarks The business background of the project, such as the change purposes and expected goals. After you specify the preceding information, click Submit in the lower-right corner of the panel.
After the task is generated, the Task Center panel automatically appears, where you can view the task status and task information. For more information, see Partitioning plan task.
