SWITCHOVER PLUGGABLE DATABASE

This command switches the role of a source PDB with its designated target PDB.

Prerequisites

  • Connect to the target database.

  • The specified target PDB must exist in the target database and must be configured as a DG PDB.

Syntax

SWITCHOVER TO PLUGGABLE DATABASE <pdb_name> AT <target_db_unique_name>;

Command Parameters

pdb_name
Name of the target PDB to which source PDB operations must be switched. The name specified must the same as that used when you ran the ADD PLUGGABLE DATABASE command to set up the source PDB.
target_db_unique_name
Name of the target database that contains the target PDB.

Usage Notes

  • The broker verifies that the source PDB is open.

  • The broker verifies the named PDB is a DG PDB at the specified database and redo apply is running.

Examples

Example 10-17 Switching Over to a Target PDB

This example switches operations of the source PDB with the target PDB named dgpdb_sales that is contained in the target database cdb_newyork.

DGMGRL> SWITCHOVER TO PLUGGABLE DATABASE dgpdb_sales AT newyork;