zoukankan      html  css  js  c++  java
  • 详解Oracle的unlimited tablespace系统权限

    1. 系统权限unlimited tablespace是隐含dba, resource角色中的一个系统权限.

    2. 系统权限unlimited tablespace不能被授予role, 可以被授予用户.

    3. 系统权限unlimited tablespace不会随着resource, dba被授予role而授予给用户.

    实验1

    SQL> create user u1 identified by u1;

    User created.

    SQL> grant connect, resource to u1;

    Grant succeeded.

    SQL> select * from dba_role_privs a where a.grantee='U1';

    GRANTEE              GRANTED_ROLE         ADM DEF

    -------------------- -------------------- --- ---

    U1                   RESOURCE             NO  YES

    U1                   CONNECT              NO  YES

    SQL> select * from dba_sys_privs a where a.grantee='U1';

    GRANTEE              PRIVILEGE            ADM

    -------------------- -------------------- ---

    U1                   UNLIMITED TABLESPACE NO

    SQL> revoke unlimited tablespace from u1;

    Revoke succeeded.

    SQL> select * from dba_sys_privs a where a.grantee='U1';

    no rows selected

    实验2

    SQL> create role r1;

    Role created.

    SQL> grant unlimited tablespace to r1;

    ORA-01931: cannot grant UNLIMITED TABLESPACE to a role

    不能受权给角色r1.

     

    SQL> grant unlimited tablespace to u1;

    Grant succeeded.

    不能受权给用户u1.

    实验3

    SQL> revoke resource from u1;

    Revoke succeeded.

    SQL> grant resource to r1;

    Grant succeeded.

    SQL> grant r1 to u1;

    Grant succeeded.

    SQL> select * from dba_role_privs a where a.grantee='U1';

    GRANTEE              GRANTED_ROLE         ADM DEF

    -------------------- -------------------- --- ---

    U1                   R1                   NO  YES

    U1                   CONNECT              NO  YES

    SQL> select * from dba_sys_privs a where a.grantee='U1';

    no rows selected

    系统权限中没有unlimit tablespace系统权限.

  • 相关阅读:
    ES6新特性:使用export和import实现模块化
    常见Linux/Unix开发辅助命令什锦
    Spark高速上手之交互式分析
    Lua中的元表与元方法
    explicit 构造函数
    【排序】基数排序(计数排序、桶排序)
    拓展训练—心得体会
    poj3411--Paid Roads(bfs+状压)
    点击单选button后的文字就可以选定相应单选button
    hdu 2349 最小生成树
  • 原文地址:https://www.cnblogs.com/seasonzone/p/3496117.html
Copyright © 2011-2022 走看看