sexta-feira, 8 de abril de 2011

Verificando Roles e Grants de um usuário

 

Select Usuario,Permissao

from(

Select x.Grantee As Usuario ,y.Granted_Role As Permissao

From Dba_Role_Privs X

join Role_Role_Privs y on y.Role = x.Granted_Role

 

union all

 

Select x.Grantee As Usuario ,y.PRIVILEGE As Permissao

From Dba_Role_Privs X

join Role_sys_Privs y on y.Role = x.Granted_Role

 

)

where usuario = upper(&usuario)

order by usuario desc

Nenhum comentário :

Postar um comentário

Related Posts Plugin for WordPress, Blogger...