DBA/Oracle/dyamicsql_example.sql
2020-09-10 13:26:26 -05:00

2 lines
248 B
SQL

select distinct 'GRANT '|| privilege ||' ON '||owner||'.'||table_name||' TO DC4UI_APP_RW;' from dba_tab_privs where grantee='DC4UI_APP_RW' AND table_name not in (SELECT DISTINCT table_name from dba_tab_privs where grantee = 'DC4UISANDBOX_APP_RW');