Moves a partition or subpartition to a different tablespace. Because PolarDB uses a shared distributed storage architecture where multiple compute nodes share a single copy of data, it does not support physical tablespaces. ALTER TABLE MOVE PARTITION is supported for compatibility only; it does not change the data's physical storage location.
To run this command, you must be the table owner or have the ALTER permission for the table.
Synopsis
ALTER TABLE MOVE PARTITION has two forms:
Move a partition to a new tablespace:
ALTER TABLE table_name
MOVE PARTITION partition_name
TABLESPACE tablespace_name;Move a subpartition to a new tablespace:
ALTER TABLE table_name
MOVE SUBPARTITION subpartition_name
TABLESPACE tablespace_name;Parameters
Parameter | Required | Description | Example |
| Yes | The name of the table that contains the partition. |
|
| Yes | The name of the partition to move. |
|
| Yes | The name of the subpartition to move. |
|
| Yes | The name of the destination tablespace. |
|