Want to post your scripts here in this blog ? Email it to snojha@gmail.com. You will be rewarded for your scripts if selected by our experts.

Wednesday, January 13, 2010

Account Permissions

select grantee||': '||privilege||': '||owner||'.'||table_name
from dba_tab_privs where grantee not in (select role from dba_roles)
and grantee not in ('ORDSYS','OUTLN','PUBLIC','SYS','SYSTEM',
'CTXSYS','MDSYS','ODM','OLAPSYS','WKSYS','WMSYS','XDB','LBACSYS',
'OSE$HTTP$ADMIN','AURORA$JIS$UTILITY$','REPADMIN','PERFSTAT','SYSMAN')
and table_name<>'DBMS_REPCAT_INTERNAL_PACKAGE'
and table_name not like '%RP'
and grantee not in
(select grantee from dba_tab_privs where table_name in ('DBMS_DEFER','DEFLOB'))
and grantee not in (select grantee from dba_role_privs where granted_role='DBA');

No comments: