CANCEL-ALTER-TABLE
CANCEL-ALTER-TABLEβ
Nameβ
CANCEL ALTER TABLE
Descriptionβ
This statement is used to undo an ALTER operation.
- Undo the ALTER TABLE COLUMN operation
grammar:
CANCEL ALTER TABLE COLUMN
FROM db_name.table_name
- Undo the ALTER TABLE ROLLUP operation
grammar:
CANCEL ALTER TABLE ROLLUP
FROM db_name.table_name
- Batch cancel rollup operations based on job id
grammar:
CANCEL ALTER TABLE ROLLUP
FROM db_name.table_name (jobid,...)
Notice:
- This command is an asynchronous operation. You need to use
show alter table rollup
to check the task status to confirm whether the execution is successful or not.
- Undo the ALTER CLUSTER operation
grammar:
(To be implemented...)
Exampleβ
-
Undo the ALTER COLUMN operation on my_table.
[CANCEL ALTER TABLE COLUMN]
CANCEL ALTER TABLE COLUMN
FROM example_db.my_table;
-
Undo the ADD ROLLUP operation under my_table.
[CANCEL ALTER TABLE ROLLUP]
CANCEL ALTER TABLE ROLLUP
FROM example_db.my_table;
-
Undo the ADD ROLLUP operation under my_table according to the job id.
[CANCEL ALTER TABLE ROLLUP]
CANCEL ALTER TABLE ROLLUP
FROM example_db.my_table(12801,12802);
Keywordsβ
CANCEL, ALTER, TABLE, CANCEL ALTER