среда, 25 октября 2017 г.

Flashback archive grants

You cant find grants for flashback archive tables in DBA_TAB_PRIVS. To determine which users have grants to flashback archives given with

GRANT FLASHBACK ARCHIVE ON SOME_FDA TO SOME_USER;

you have to use query

SELECT u.username, a.*
FROM sys.SYS_FBA_USERS au, dba_users u, dba_flashback_archive a
WHERE u.user_id = au.user#
  AND au.fa# = a.flashback_archive#;

NB: using dba_users is enough, because you can’t grant Flashback archive to role

GRANT FLASHBACK ARCHIVE ON FDA TO FDA_ROLE;
ORA-55625: Cannot grant Flashback Archive privilege to a role

Комментариев нет: