Note
This view is available starting with V2.2.77.
Purpose
This view displays all roles in the current tenant.
Applicability
This view is applicable only to OceanBase Database in Oracle mode.
Columns
| Column | Type | Nullable | Description |
|---|---|---|---|
| ROLE | VARCHAR2(30) | NO | The name of the role. |
| PASSWORD_REQUIRED | VARCHAR2(8) | NO | Indicates whether a password is required for the role. This field cannot correctly display the password requirement for roles. |
| AUTHENTICATION_TYPE | VARCHAR2(11) | NO | Indicates the authentication mechanism for the role. This field is not supported. |
Sample query
Query all roles in the current tenant.
obclient> SELECT * FROM SYS.DBA_ROLES;
The query result is as follows:
+---------------------+-------------------+---------------------+
| ROLE | PASSWORD_REQUIRED | AUTHENTICATION_TYPE |
+---------------------+-------------------+---------------------+
| CONNECT | NO | NONE |
| RESOURCE | NO | NONE |
| DBA | NO | NONE |
| PUBLIC | NO | NONE |
| STANDBY_REPLICATION | NO | NONE |
| ROLE1 | NO | NONE |
+---------------------+-------------------+---------------------+
6 rows in set
