Here i am exploring the concept of unplugging a database in 12c multi-tenant setup architecture.
SQL> alter pluggable database pdb2 unplug into ‘/oracle/DCE/pdb2_unplug.xml’;
If you query:
select * from cdb_pdbs;
database status changed to —–> UNPLUGGED
The database is unplugged but not dropped and you can still see it any many data dictionary views:
To drop pluggable database:
SQL> DROP PLUGGABLE DATABASE PDB2 INCLUDING DATAFILES;
Checking the data dictionary, the pluggable database doesn’t exist anymore:
***** Its important to know that unplugging the database could cause problems while patching/upgrading, so its better to drop your database before applying any patches to avoid problems.
Hope this information is useful.