REVOKE_ FROM_ PUBLIC_ APPLICATION_ ROLE¶
Revokes an administrator-revocable capability from the SNOWFLAKE.PUBLIC application role. The capability stays revoked across Snowflake
upgrades until you restore it with GRANT_TO_PUBLIC_APPLICATION_ROLE.
Syntax¶
Arguments¶
'kind'The type of capability:
PRIVILEGE,APP_ROLE, orDB_ROLE. In the output ofSHOW GRANTS TO APPLICATION ROLE SNOWFLAKE.PUBLIC, these correspond to agranted_onvalue ofACCOUNT,APPLICATION_ROLE, orDATABASE_ROLE.'name'The name of the capability. For a privilege, replace spaces with underscores; for example,
USE_AI_FUNCTIONS. For a role, omit theSNOWFLAKE.prefix; for example,CORTEX-MODEL-ROLE-ALL.
Returns¶
Returns a VARCHAR value in the form Revoked <name>.
Access control requirements¶
A role must be granted the SNOWFLAKE.SNOWFLAKE_PUBLIC_GRANT_ADMIN application role to call this stored procedure. By default, only
the ACCOUNTADMIN role is granted this application role. ACCOUNTADMIN can grant it to other roles:
Usage notes¶
- To list the capabilities granted to
SNOWFLAKE.PUBLIC, runSHOW GRANTS TO APPLICATION ROLE SNOWFLAKE.PUBLIC. - Users who receive the capability only through
SNOWFLAKE.PUBLIClose it. Before you revoke a capability, grant it directly to the roles that still need it. - Use this stored procedure instead of a
REVOKEstatement. AREVOKEstatement doesn’t remove the capability fromSNOWFLAKE.PUBLICor persist across Snowflake upgrades. - The stored procedure returns an error if the capability isn’t administrator-revocable.
- Revoking a capability that is already revoked succeeds.