Search notes:

Oracle: SQL functions that are useful in a CDB

SQL functions that are useful in a container database (CDB) include:
These functions return 0 if executed in a non-CDB.

CON_NAME_TO_ID

select
   con.name,
   con_name_to_id(con.name),
   con.con_id
from
   v$containers con;

CON_ID_TO_CON_NAME

select
   dual.dummy,
   con_id,
   con_id_to_con_name(con_id)  con_name
from
   containers(dual);

Index