Oracle Database 12c: Advanced Administration — Question 84
You are administering a multitenant container database (CDB) that contains multiple pluggable databases (PDBs). You are connected to cdb$root as the sys user.
You execute the commands:
SQL> CREATE USER C##ADMIN IDENTIFIED BY orcll23;
SQL> CREATE ROLE C##CONNECT;
SQL> GRANT CREATE SESSION, CREATE TABLE, SELECT ANY TABLE TO C##CONNECT;
SQL> GRANT C##CONNECT to C##ADMIN CONTAINER=ALL;
Which statement is true about the c##connect role?
Answer options
- A. It is created only in cdb$root and cannot be granted to the c##admin user with the container=all clause.
- B. It is granted to the c##admin user only in the CDB.
- C. It is granted to the c##admin user in all PDBs and can be granted only to a local user in a PDB.
- D. It is granted to the c##admin user in all PDBs and can be granted object and system privileges for a PDB.
Correct answer: C
Explanation
The correct answer is C because the C##CONNECT role is granted to the C##ADMIN user in all PDBs when using the CONTAINER=ALL clause. Option A is incorrect as the role can be granted to the user across the container. Option B is wrong because the role is not limited to the CDB only. Option D is misleading as the role's primary function is to be granted to a local user in a PDB, not to extend privileges directly.