12.2 Drop Data Role

Use the DROP DATA ROLE command to remove a data role from the database.

Required privilege

The DROP DATA ROLE system privilege.

Syntax

DROP DATA ROLE [ IF EXISTS ] data_role;

Parameters

Parameter Description

data_role

The name of the data role to be dropped.

Usage notes and restrictions

  • When IF EXISTS is specified:
    • If the data role does not exist, the statement is a no-op. No error is raised.
    • If the data role exists, it is dropped.
  • When IF EXISTS is omitted:
    • If the data role does not exist, an error is raised.
    • If the data role exists, it is dropped.

For syntax diagrams and additional details, see DROP DATA ROLE in Oracle AI Database SQL Language Reference.

Example 12-5 Drop data role

Drop an existing data role, employee_role.

DROP DATA ROLE employee_role;