Rename A Pluggable Database ( PDB)

Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
Breadcrumb Abstract Shape
  • User AvatarANKUSH THAVALI
  • 17 Aug, 2023
  • 0 Comments
  • 53 Secs Read

Rename A Pluggable Database ( PDB)

How to rename a Pluggable Database (PDB?)

In this blog , we will see how to Rename A Pluggable Database ( PDB) ?

  1. Start Pluggable Database with restrict mode :
SQL> alter session set container=pdbtest;

Session altered.

SQL>
SQL>  shutdown immediate;
Pluggable Database closed.
SQL> startup open restrict
Pluggable Database opened.

Rename the PDB

SQL> alter pluggable database pdbtest rename global_name to pdbdb;

Pluggable database altered.

SQL>
SQL> show con_name;

CON_NAME
------------------------------
PDBDB
SQL>

Restart the PDB

SQL> shutdown immediate;
Pluggable Database closed.
SQL>
SQL>
SQL> startup
Pluggable Database opened.

SQL> alter session set container=CDB$ROOT;

Session altered.

SQL> show pdbs;

    CON_ID CON_NAME                       OPEN MODE  RESTRICTED
---------- ------------------------------ ---------- ----------
         2 PDB$SEED                       READ ONLY  NO
         3 PDBDB                          READ WRITE NO
         4 ABC                            READ WRITE NO
SQL>