IS_APPLICATION_ROLE_IN_SESSION

functionsupportedAccess control (grants, roles)

docs.snowflake.com ↗

Context functions

Verifies whether the application role is activated in the consumer’s current session.

Syntax

IS_APPLICATION_ROLE_IN_SESSION( '<string_literal>' )

Parameters

NameRequiredDescription
'string_literal'requiredThe application role name.

Returns

- TRUE when the specified role name is activated in the consumer’s current session. The function always uses the consumer’s current session and returns TRUE when the application role is granted to the consumer using the function. The function does not return TRUE when the application calls the function because application roles are owned but not granted to the app. - FALSE when the specified application role name is not activated in the consumer’s current session.

Usage notes

See also

Referenced by