|
| 1 | +--- |
| 2 | +subcategory: "Relational Database Service (RDS)" |
| 3 | +layout: "huaweicloud" |
| 4 | +page_title: "HuaweiCloud: huaweicloud_rds_pg_table_restore" |
| 5 | +description: |- |
| 6 | + Manages an RDS instance PostgreSQL table restore resource within HuaweiCloud. |
| 7 | +--- |
| 8 | + |
| 9 | +# huaweicloud_rds_pg_table_restore |
| 10 | + |
| 11 | +Manages an RDS instance PostgreSQL table restore resource within HuaweiCloud. |
| 12 | + |
| 13 | +## Example Usage |
| 14 | + |
| 15 | +```hcl |
| 16 | +variable "instance_id" {} |
| 17 | +
|
| 18 | +resource "huaweicloud_rds_pg_table_restore" "test" { |
| 19 | + instance_id = var.instance_id |
| 20 | + restore_time = 1754954459000 |
| 21 | +
|
| 22 | + databases { |
| 23 | + database = "test1" |
| 24 | +
|
| 25 | + schemas { |
| 26 | + schema = "test1" |
| 27 | +
|
| 28 | + tables { |
| 29 | + old_name = "table1" |
| 30 | + new_name = "table1_update" |
| 31 | + } |
| 32 | + } |
| 33 | + } |
| 34 | +} |
| 35 | +``` |
| 36 | + |
| 37 | +## Argument Reference |
| 38 | + |
| 39 | +The following arguments are supported: |
| 40 | + |
| 41 | +* `region` - (Optional, String, ForceNew) The region in which the RDS instance exists. If omitted, the |
| 42 | + provider-level region will be used. Changing this creates a new resource. |
| 43 | + |
| 44 | +* `instance_id` - (Required, String, NonUpdatable) Specifies the ID of RDS PostgreSQL instance. |
| 45 | + |
| 46 | +* `restore_time` - (Required, Int, NonUpdatable) Specifies the restoration time point. A timestamp in milliseconds is used. |
| 47 | + |
| 48 | +* `databases` - (Required, List, NonUpdatable) Specifies the list of databases to restore. |
| 49 | + The [databases](#databases_struct) structure is documented below. |
| 50 | + |
| 51 | +<a name="databases_struct"></a> |
| 52 | +The `databases` block supports: |
| 53 | + |
| 54 | +* `database` - (Required, String, NonUpdatable) Specifies the name of the database that contains the tables to restore. |
| 55 | + |
| 56 | +* `schemas` - (Required, List, NonUpdatable) Specifies a list of schemas within the database. |
| 57 | + The [schemas](#schemas_struct) structure is documented below. |
| 58 | + |
| 59 | +<a name="schemas_struct"></a> |
| 60 | +The `schemas` block supports: |
| 61 | + |
| 62 | +* `schema` - (Required, String, NonUpdatable) Specifies the name of the schema containing the tables to be restored. |
| 63 | + |
| 64 | +* `tables` - (Required, List, NonUpdatable) Specifies a list of tables to be restored. |
| 65 | + The [tables](#tables_struct) structure is documented below. |
| 66 | + |
| 67 | +<a name="tables_struct"></a> |
| 68 | +The `tables` block supports: |
| 69 | + |
| 70 | +* `old_name` - (Required, String, NonUpdatable) Specifies the name of the table before restoration. |
| 71 | + |
| 72 | +* `new_name` - (Required, String, NonUpdatable) Specifies the name of the table after restoration. |
| 73 | + |
| 74 | +## Attribute Reference |
| 75 | + |
| 76 | +In addition to all arguments above, the following attribute is exported: |
| 77 | + |
| 78 | +* `id` - The resource ID. The value is the restore job ID. |
| 79 | + |
| 80 | +## Timeouts |
| 81 | + |
| 82 | +This resource provides the following timeouts configuration options: |
| 83 | + |
| 84 | +* `create` - Default is 60 minutes. |
0 commit comments