Skip to main content

external_container_databases

Creates, updates, deletes, gets or lists an external_container_databases resource.

Overview​

Nameexternal_container_databases
TypeResource
Idoci.database.external_container_databases

Fields​

The following fields are returned by SELECT queries:

The external container database.

NameDatatypeDescription
idstringThe [OCID](/Content/General/Concepts/identifiers.htm) of the Oracle Cloud Infrastructure external database resource.
characterSetstringThe character set of the external database.
compartmentIdstringThe [OCID](/Content/General/Concepts/identifiers.htm) of the compartment.
databaseConfigurationstringThe Oracle Database configuration (RAC, SINGLE_INSTANCE)
databaseEditionstringThe Oracle Database Edition that applies to all the databases on the DB system. Exadata DB systems and 2-node RAC DB systems require ENTERPRISE_EDITION_EXTREME_PERFORMANCE. (STANDARD_EDITION, ENTERPRISE_EDITION, ENTERPRISE_EDITION_HIGH_PERFORMANCE, ENTERPRISE_EDITION_EXTREME_PERFORMANCE, ENTERPRISE_EDITION_DEVELOPER)
databaseManagementConfigobjectThe configuration of the Database Management service.
databaseVersionstringThe Oracle Database version.
dbIdstringThe Oracle Database ID, which identifies an Oracle Database located outside of Oracle Cloud.
dbPacksstringThe database packs licensed for the external Oracle Database.
dbUniqueNamestringThe DB_UNIQUE_NAME of the external database.
definedTagsobjectDefined tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm).
displayNamestringThe user-friendly name for the external database. The name does not have to be unique.
freeformTagsobjectFree-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](/Content/General/Concepts/resourcetags.htm). Example: {"Department": "Finance"}
lifecycleDetailsstringAdditional information about the current lifecycle state.
lifecycleStatestringThe current state of the Oracle Cloud Infrastructure external database resource. (PROVISIONING, NOT_CONNECTED, AVAILABLE, UPDATING, TERMINATING, TERMINATED, FAILED)
ncharacterSetstringThe national character of the external database.
stackMonitoringConfigobjectThe configuration of Stack Monitoring for the external database.
systemTagsobjectSystem tags for this resource. Each key is predefined and scoped to a namespace. For more information, see [Resource Tags](/Content/General/Concepts/resourcetags.htm).
timeCreatedstring (date-time)The date and time the database was created.
timeZonestringThe time zone of the external database. It is a time zone offset (a character type in the format '[+|-]TZH:TZM') or a time zone region name, depending on how the time zone value was specified when the database was created / last altered.

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectexternalContainerDatabaseId, regionopc-request-idGets information about the specified external container database.
listselectcompartmentId, regionopc-request-id, limit, page, sortBy, sortOrder, lifecycleState, displayNameGets a list of the external container databases in the specified compartment.<br />
createinsertregion, compartmentId, displayNameopc-retry-token, opc-request-idCreates a new external container database resource.
updateupdateexternalContainerDatabaseId, region, displayNameif-match, opc-request-idUpdates the properties of<br />an [ExternalContainerDatabase](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails) resource,<br />such as the display name.<br />
deletedeleteexternalContainerDatabaseId, regionopc-request-id, if-matchDeletes the [external container database](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails)<br />resource. Any external pluggable databases registered under this container database must be deleted in<br />your Oracle Cloud Infrastructure tenancy prior to this operation.<br />
change_compartmentexecexternalContainerDatabaseId, region, compartmentIdopc-retry-token, opc-request-id, if-matchMove the [external container database](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails)<br />and its dependent resources to the specified compartment.<br />For more information about moving external container databases, see<br />[Moving Database Resources to a Different Compartment](/Content/Database/Concepts/databaseoverview.htm#moveRes).<br />

Parameters​

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
compartmentIdstringThe compartment [OCID](/Content/General/Concepts/identifiers.htm).
externalContainerDatabaseIdstringThe ExternalContainerDatabase [OCID](/Content/General/Concepts/identifiers.htm).
regionstringOCI region identifier (e.g. us-ashburn-1, ap-sydney-1); resolves from OCI_REGION when not supplied in the query. (default: us-ashburn-1, x-stackQL-envVar: OCI_REGION)
displayNamestringA filter to return only resources that match the entire display name given. The match is not case sensitive.
if-matchstringFor optimistic concurrency control. In the PUT or DELETE call for a resource, set the if-match parameter to the value of the etag from a previous GET or POST response for that resource. The resource will be updated or deleted only if the etag you provide matches the resource's current etag value.
lifecycleStatestringA filter to return only resources that match the specified lifecycle state.
limitintegerThe maximum number of items to return per page.
opc-request-idstringUnique identifier for the request.
opc-retry-tokenstringA token that uniquely identifies a request so it can be retried in case of a timeout or server error without risk of executing that same action again. Retry tokens expire after 24 hours, but can be invalidated before then due to conflicting operations (for example, if a resource has been deleted and purged from the system, then a retry of the original creation request may be rejected).
pagestringThe pagination token to continue listing from.
sortBystringThe field to sort by. You can provide one sort order (sortOrder). Default order for TIMECREATED is descending. Default order for DISPLAYNAME is ascending. The DISPLAYNAME sort order is case sensitive.
sortOrderstringThe sort order to use, either ascending (ASC) or descending (DESC).

SELECT examples​

Gets information about the specified external container database.

SELECT
id,
characterSet,
compartmentId,
databaseConfiguration,
databaseEdition,
databaseManagementConfig,
databaseVersion,
dbId,
dbPacks,
dbUniqueName,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
ncharacterSet,
stackMonitoringConfig,
systemTags,
timeCreated,
timeZone
FROM oci.database.external_container_databases
WHERE externalContainerDatabaseId = '{{ externalContainerDatabaseId }}' -- required
AND region = '{{ region }}' -- required
AND opc-request-id = '{{ opc-request-id }}'
;

INSERT examples​

Creates a new external container database resource.

INSERT INTO oci.database.external_container_databases (
compartmentId,
definedTags,
displayName,
freeformTags,
region,
opc-retry-token,
opc-request-id
)
SELECT
'{{ compartmentId }}' /* required */,
'{{ definedTags }}',
'{{ displayName }}' /* required */,
'{{ freeformTags }}',
'{{ region }}',
'{{ opc-retry-token }}',
'{{ opc-request-id }}'
RETURNING
id,
characterSet,
compartmentId,
databaseConfiguration,
databaseEdition,
databaseManagementConfig,
databaseVersion,
dbId,
dbPacks,
dbUniqueName,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
ncharacterSet,
stackMonitoringConfig,
systemTags,
timeCreated,
timeZone
;

UPDATE examples​

Updates the properties of<br />an [ExternalContainerDatabase](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails) resource,<br />such as the display name.<br />

UPDATE oci.database.external_container_databases
SET
definedTags = '{{ definedTags }}',
displayName = '{{ displayName }}',
freeformTags = '{{ freeformTags }}'
WHERE
externalContainerDatabaseId = '{{ externalContainerDatabaseId }}' --required
AND region = '{{ region }}' --required
AND displayName = '{{ displayName }}' --required
AND if-match = '{{ if-match}}'
AND opc-request-id = '{{ opc-request-id}}'
RETURNING
id,
characterSet,
compartmentId,
databaseConfiguration,
databaseEdition,
databaseManagementConfig,
databaseVersion,
dbId,
dbPacks,
dbUniqueName,
definedTags,
displayName,
freeformTags,
lifecycleDetails,
lifecycleState,
ncharacterSet,
stackMonitoringConfig,
systemTags,
timeCreated,
timeZone;

DELETE examples​

Deletes the [external container database](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails)<br />resource. Any external pluggable databases registered under this container database must be deleted in<br />your Oracle Cloud Infrastructure tenancy prior to this operation.<br />

DELETE FROM oci.database.external_container_databases
WHERE externalContainerDatabaseId = '{{ externalContainerDatabaseId }}' --required
AND region = '{{ region }}' --required
AND opc-request-id = '{{ opc-request-id }}'
AND if-match = '{{ if-match }}'
;

Lifecycle Methods​

Move the [external container database](#/en/database/latest/datatypes/CreateExternalContainerDatabaseDetails)<br />and its dependent resources to the specified compartment.<br />For more information about moving external container databases, see<br />[Moving Database Resources to a Different Compartment](/Content/Database/Concepts/databaseoverview.htm#moveRes).<br />

EXEC oci.database.external_container_databases.change_compartment
@externalContainerDatabaseId='{{ externalContainerDatabaseId }}' --required,
@region='{{ region }}' --required,
@opc-retry-token='{{ opc-retry-token }}',
@opc-request-id='{{ opc-request-id }}',
@if-match='{{ if-match }}'
@@json=
'{
"compartmentId": "{{ compartmentId }}"
}'
;