Extracted from: http://docs.oracle.com/cd/E16655_01/network.121/e17607/authorization.htm#DBSEG806
To enable common users to access data about specific PDBs, you must run the ALTER USER statement in the root.
Example 4-6 shows how to run the ALTER USER statement to enable the common user c##hr_admin to view information pertaining to the CDB$ROOT, SALES_PDB, and hrpdb containers in all container data objects that he can access, using the V$SESSION view.
Example 4-6 Enabling a Common User to View Specific Object Data
CONNECT SYSTEM@root
Enter password: password
Connected.
ALTER USER c##hr_admin
SET CONTAINER_DATA = (CDB$ROOT, SALESPDB, HRPDB)
FOR V$SESSION CONTAINER=CURRENT;
In this specification:
CDB$ROOT,SALES_PDB,hrpdbrefer to the containers that must be accessible to userc##hr_admin. You must includeCDB$ROOT.
FOR V$SESSIONspecifies theCONTAINER_DATAdynamic view, which common userc##hr_adminwill query.
CONTAINER = CURRENTmust be specified because when you are connected to the root,CONTAINER=ALLis the default for theALTER USERstatement, but modification of theCONTAINER_DATAattribute must be restricted to the root.
No comments:
Post a Comment