Monday, September 16, 2013

Oracle Database 12c - Drop PDB

Drop pluggable database

Unplugged database can not be opened again. This database can be dropped using keep datafiles or including datafiles.

SQL> drop pluggable database dx12p1 keep datafiles;

Pluggable database dropped.

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 DX12P                          READ WRITE NO

SQL> drop pluggable database dx12p including datafiles;

Pluggable database dropped.

SQL> show pdbs

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO

No comments:

Post a Comment