用户管理
创建/修改用户
create/alter user test
identified by test
account lock
password expire;
授予用户
grant create session to test;
grant create table to test;
alter user test account unlock;
删除用户
drop user test;
drop user test cascade;--用户有创建表时需要cascade
权限管理
授予test1查询emp表和更新emp表的sal列
grant select ,update(sal) on scott.emp to test1 with grant option;
回收emp表查询
revoke select on scott.emp from test1;
角色管理
角色创建:
create role role;
删除角色:
drop role role;
用户上角色授予:
grant role to user;
角色回收:
revoke role from user;