Oracle辅导:oraclegrant是否赋予权限(4)
grant create session to public; //表示把创建表的权限赋予所有人 select * from user_sys_privs; //返回当前用户的所有系统权限对象权限
grant select on mytab to test;
grant all on mytab to test;
revoke select on mytab from test;
revoke all on mytab from test;
select * from user_tab_privs; //返回当前用户所有的对象权限
对象权限可以控制到列
grant update(name) on mytab to test;
grant insert(id) on mytab to test;
select * from user_col_privs;
注意、:查询和删除不能控制到列
需要有commit的 insert update insert
权限的传递
系统权限的传递:
grant alter table to A with admin option;
那么A可以通过把该权限传递给B,如果想B也可以传递下去那么可以也带上with admin option
grant alter table to B;
对象权限的传递:
grant select on mytab to A with grant option;
那么A可以把在表mytab的select权限赋予给B,如果B想也能传递该select权限也可以带上with grant option
grant select on mytab to B;
页:
[1]