How to query the permissions on an Oracle directory?

前端 未结 4 1889
借酒劲吻你
借酒劲吻你 2021-02-13 06:59

I have a directory in all_directories, but I need to find out what permissions are associated with it, i.e. what has been granted on it?

4条回答
  •  陌清茗
    陌清茗 (楼主)
    2021-02-13 07:19

    This should give you the roles, users and permissions granted on a directory:

    SELECT * 
      FROM all_tab_privs 
     WHERE table_name = 'your_directory';  --> needs to be upper case
    

    And yes, it IS in the all_TAB_privs view ;-) A better name for that view would be something like "ALL_OBJECT_PRIVS", since it also includes PL/SQL objects and their execute permissions as well.

提交回复
热议问题