1.7 KiB
1.7 KiB
title, language
| title | language |
|---|---|
| RECOVER | en |
RECOVER
Description
This statement is used to restore previously deleted databases, tables, or partitions Grammar: 1)24674;"22797database; RECOVER DATABASE db_name; 2) 恢复 table RECOVER TABLE [db_name.]table_name; 3)24674;"22797partition RECOVER PARTITION partition name FROM [dbu name.]table name;
Explain:
- This operation can only recover the meta-information deleted in the previous period of time. The default is 1 day.(You can configure it with the
catalog_trash_expire_secondparameter in fe.conf) - If new meta-information of the same name and type is created after deleting meta-information, the previously deleted meta-information cannot be restored.
example
-
Restore the database named example_db RECOVER DATABASE example_db;
-
Restore table named example_tbl RECOVER TABLE example_db.example_tbl;
-
Restore partition named P1 in example_tbl RECOVER PARTITION p1 FROM example_tbl;
keyword
RECOVER