Background documentationCREATE ROLE Statement (create_role_statement) Locate this document in the navigation structure

 

The CREATE ROLE statement (create_role_statement) defines a role.

Structure

Syntax Syntax

  1. <create_role_statement> ::=
      CREATE ROLE <role_name> [IDENTIFIED BY <password>]
End of the code.
Examples

SQL Tutorial, Roles

Explanation

The current database user must be a database administrator (DBA user).

The role name must not be the same as the name of an existing role, database user, or user group.