SET ROLE Syntax Elements - Analytics Database - Teradata Vantage

SQL Data Definition Language Syntax and Examples

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2024-10-04
dita:mapPath
jco1628111346878.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
mdr1472255012272
lifecycle
latest
Product Category
Teradata Vantage™
role_name
Name of the role to set as the current role for a session.
You can use the SET ROLE role_name syntax to enable an externally-assigned role plus any of its nested database roles within a session while disabling all other roles.
EXTERNAL
All external roles mapped to the user are to be made active for the session.
The EXTERNAL keyword is useful only for directory users who are mapped to both a user object and one or more external role objects in the directory, where the system defaults to the privileges for the mapped user.
If the directory user is mapped only to external role objects and not mapped to a database user object, all the external roles are active by default.
NONE
Disables the current role, whether directory- or database-assigned, for a session.
NULL
Null role is to be made current for the session.
ALL
All the roles that have been directly and indirectly granted to a user, whether directory- or database-assigned, become current and active.