CURRENT_AVAILABLE_ROLES

functionpartialAccess control (grants, roles)

docs.snowflake.com ↗

Context functions

Returns a list of all account-level roles granted to the current user. The list includes all roles that are granted directly to the user plus all account-level roles lower in the hierarchies of these roles.

Syntax

CURRENT_AVAILABLE_ROLES()

Returns

Returns a string (VARCHAR) that is a JSON-encoded list of available account-level roles. The returned value can be passed to the PARSE_JSON function to get a VARIANT that contains a list of all the available roles.

Usage notes

Known gaps

Parts not fully supported, and recorded divergences from Snowflake.

See also