查看用户权限

1.查看所有用户:
  select * from dba_users;
  select * from all_users;

 

2.查看当前登录的用户:
  select * from user_users;


3.查看所有用户的系统权限
  select * from dba_sys_privs;

 

4.查看当前登录用户所拥有的系统权限
  select * from user_sys_privs;

 

5.查看当前登录用户所拥有的角色及其角色对应的系统权限

  select * from role_sys_privs;


6.查看所有用户拥有的对象权限:
  select * from dba_tab_privs;
  select * from all_tab_privs;

 

7.查看当前登录的用户拥有的对象权限:
  select * from user_tab_privs;


8.查看所有角色:
  select * from dba_roles;


9.查看所有用户的角色

  select * from dba_role_privs;

 

10.查看当前登录的用户所拥有的角色:
  select * from user_role_privs;

 

11.查看哪些用户有sysdba或sysoper系统权限

  select * from V$PWFILE_USERS

 

12.查看所有系统权限:

  select name from sys.system_privilege_map

 

13.查看某个用户所拥有的系统权限及其拥有的角色对应的系统权限:

  SELECT PRIVILEGE
  FROM DBA_SYS_PRIVS
  WHERE GRANTEE = 'APPS'
  UNION
  SELECT PRIVILEGE
  FROM DBA_SYS_PRIVS
  WHERE GRANTEE IN
       (SELECT GRANTED_ROLE FROM DBA_ROLE_PRIVS WHERE GRANTEE = 'APPS');

 

 

你可能感兴趣的:(user,Oracle数据库类)