» Data Source: oci_database_databases
This data source provides the list of Databases in Oracle Cloud Infrastructure Database service.
Gets a list of the databases in the specified database home.
» Example Usage
data "oci_database_databases" "test_databases" {
#Required
compartment_id = "${var.compartment_id}"
db_home_id = "${oci_database_db_home.test_db_home.id}"
#Optional
db_name = "${var.database_db_name}"
state = "${var.database_state}"
}
» Argument Reference
The following arguments are supported:
-
compartment_id
- (Required) The compartment OCID. -
db_home_id
- (Required) A database home OCID. -
db_name
- (Optional) A filter to return only resources that match the entire database name given. The match is not case sensitive. -
state
- (Optional) A filter to return only resources that match the given lifecycle state exactly.
» Attributes Reference
The following attributes are exported:
-
databases
- The list of databases.
» Database Reference
The following attributes are exported:
-
character_set
- The character set for the database. -
compartment_id
- The OCID of the compartment. -
connection_strings
- The Connection strings used to connect to the Oracle Database.-
all_connection_strings
- All connection strings to use to connect to the Database. -
cdb_default
- Host name based CDB Connection String. -
cdb_ip_default
- IP based CDB Connection String.
-
-
db_backup_config
--
auto_backup_enabled
- If set to true, configures automatic backups. If you previously used RMAN or dbcli to configure backups and then you switch to using the Console or the API for backups, a new backup configuration is created and associated with your database. This means that you can no longer rely on your previously configured unmanaged backups to work.
-
-
db_home_id
- The OCID of the database home. -
db_name
- The database name. -
db_unique_name
- A system-generated name for the database to ensure uniqueness within an Oracle Data Guard group (a primary database and its standby databases). The unique name cannot be changed. -
db_workload
- The database workload type. -
defined_tags
- Defined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see Resource Tags. Example:{"Operations.CostCenter": "42"}
-
freeform_tags
- Free-form tags for this resource. Each tag is a simple key-value pair with no predefined name, type, or namespace. For more information, see Resource Tags. Example:{"Department": "Finance"}
-
id
- The OCID of the database. -
lifecycle_details
- Additional information about the current lifecycleState. -
ncharacter_set
- The national character set for the database. -
pdb_name
- The name of the pluggable database. The name must begin with an alphabetic character and can contain a maximum of eight alphanumeric characters. Special characters are not permitted. Pluggable database should not be same as database name. -
state
- The current state of the database. -
time_created
- The date and time the database was created.