You are on page 1of 1

use database exercise_db;

show grants on ACCOUNT; -- account level priviliges that have been granted to all
roles
show grants to role useradmin;--lists all priviliges granted to a role
show grants of role ACCOUNTADMIN;
create role developer comment='new developer roles';
grant usage on warehouse compute_wh to role developer;
grant usage on database exercise_db to role developer;
grant all on schema exercise_db.emp_dept to role developer;
show grants on schema exercise_db.emp_dept;

create role tester comment='new testing role'


show grants on schema streams;
grant usage on database exercise_db to role tester;
grant all on schema exercise_db.streams to role tester;

USE ROLE SECURITYADMIN;


USE ROLE ACCOUNTADMIN;
SHOW USERS;
show roles;
SHOW GRANTS TO ROLE orgadmin ;
show grants to user snowpractice;
show grants to share SFC_SAMPLES.SAMPLE_DATA;
show grants on database exercise_db;
show grants on schema streams;

SELECT * FROM TABLE(RESULT_SCAN(LAST_QUERY_ID()));


select * From table(result_scan(last_query_id()))

You might also like