SQL Создание ролей

#Create a role
CREATE ROLE role1;

#Grant permissions on table to role
GRANT INSERT, SELECT, DELETE, UPDATE ON table1 TO role1;

#Create user and assign role
CREATE USER Bob;
GRANT role1 TO Bob;
Open Ocelot