In this example, the root to which the new PDB belongs depends on the current container when the CREATE PLUGGABLE DATABASE
statement is run:
-
When the current container is the CDB root, the new PDB is created in the CDB root.
-
When the current container is an application root in an application container, the new PDB is created as an application PDB in the application root.
This example creates a remote proxy PDB named pdb1
given different factors. This example assumes the following factors:
-
The database link name to the referenced PDB’s CDB is
pdb1_link
. -
The
FILE_NAME_CONVERT
clause and theCREATE_FILE_DEST
clause are not required.Either Oracle Managed Files is enabled, or the
PDB_FILE_NAME_CONVERT
initialization parameter is set. TheSYSTEM
andSYSAUX
files will be copied to a new location based on the Oracle Managed Files configuration or the initialization parameter setting.
Given the preceding factors, the following statement creates the pdb1
proxy PDB:
CREATE PLUGGABLE DATABASE pdb1 AS PROXY FROM pdb1@pdb1_link;