Wednesday, January 3, 2018

how to get pluggable databases info from container database in oracle 12C using a common user.

This post helps you to query all pluggable databases info using common user in container database.. To do that we need to create a common user in the container database and provide neccesary grants.
As you all know we can create a common user with out "C##" in the container database by using "_" parameter..

alter session set "_ORACLE_SCRIPT"=true;

provide neccessary grants... connect/select_catalog_role/select any dictionary/ alter session/create session ... if neccesary tablespace limits too...

once the user is created you still need to run below command to read the pluggable databases information...

alter user COMMON_USER_CHECK set container_data=all;

Using this user and CDB* views now you can get all the info from container.  in one place..



Hope this helps..

No comments:

Post a Comment

PostgreSql: Useful Commands-

 1)   ************************* Users ***************************  -- List of users with roles assigned: SELECT usename AS role_name,   CASE...