Note
This view is available starting with V4.1.0.
Purpose
This view displays the policy groups of the views that the current user owns. It works with policy contexts to apply different policies to different users.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| OBJECT_NAME | VARCHAR2(128) | YES | The name of the object controlled by policies. |
| POLICY_GROUP | VARCHAR2(128) | NO | The name of the policy group. |
| COMMON | VARCHAR2(3) | NO | Reserved for compatibility. The value is fixed to NO. |
| INHERITED | VARCHAR2(3) | NO | Reserved for compatibility. The value is fixed to NO. |
Sample query
Query the policy groups of the views that the current user owns.
obclient [SYS]> SELECT * FROM SYS.USER_POLICY_GROUPS;
The query result is as follows:
+----------------+--------------+--------+-----------+
| OBJECT_NAME | POLICY_GROUP | COMMON | INHERITED |
+----------------+--------------+--------+-----------+
| V_SALES_SECURE | GROUP_SALES | NO | NO |
| V_ORDERS_CTX | GROUP_REGION | NO | NO |
+----------------+--------------+--------+-----------+
2 rows in set
References
Query the policy groups of the views that the current user can access: ALL_POLICY_GROUPS.
Query the policy groups of all views in the current tenant: DBA_POLICY_GROUPS.