Skip to content

Instantly share code, notes, and snippets.

@gagandeep-dba
gagandeep-dba / worksheet.sql
Created September 15, 2020 14:32 — forked from vdparikh/worksheet.sql
Create Read Only Snowflake Group and User
# CREATE A READ ONLY GROUP
create role read_only_svc_rl comment = 'This role is limited to querying tables';
grant role read_only_svc_rl to role sysadmin;
# GRANT USAGE ON DATABASE
grant usage on database databots_prod to role read_only_svc_rl;
# GRANT USAGE ON CURRENT SCHEMAS AND FUTURE SCHEMAS
grant usage on all schemas in database databots_prod to role read_only_svc_rl;
grant usage on future schemas in database databots_prod to role read_only_svc_rl;

Keybase proof

I hereby claim:

  • I am gagandeep-dba on github.
  • I am gdbdba (https://keybase.io/gdbdba) on keybase.
  • I have a public key ASDrofz2P5faUZ-brUXpapieVuT-E_MzpNnnpK1tUa0t7go

To claim this, I am signing this object: