Re: [Q] way to re-gernerate ROLE privilege ?

  • From: Paul Baumgartel <paul.baumgartel@xxxxxxxxx>
  • To: oracle-l@xxxxxxxxxxxxx
  • Date: Mon, 9 May 2005 15:22:14 -0400

Sure.  Generate SQL from SQL; something like:

set pages 0 feedb off trimspool on

select 'grant '||privilege||' on '||owner||'.'||table_name||' to '||grantee=
||';'
from all_tab_privs_made where grantee =3D <role>

spool grantrole.sql
/
spool off

Then run grantrole.sql on the other database.

--=20
Paul Baumgartel
paul.baumgartel@xxxxxxxxx




On 5/9/05, dba1 mcc <mccdba1@xxxxxxxxx> wrote:
> We have a ORACLE role with 50 different object
> privileges grant to it.  Does there has way to
> generate a script which I can bring this script to
> another database and re-create it?
>=20
> Thanks.
>=20
>=20
> __________________________________
> Do you Yahoo!?
> Yahoo! Mail - Helps protect you from nasty viruses.
> http://promotions.yahoo.com/new_mail
> --
> //www.freelists.org/webpage/oracle-l
>
--
//www.freelists.org/webpage/oracle-l

Other related posts: