You are on page 1of 1

Question:=>Users has requested a new read only login to view another schema's ob jects only and also toad

licensing .

CREATE ROLE scott_reader_role; GRANT scott_reader_role TO the_new_account;

BEGIN FOR r IN ( SELECT table_name x FROM dba_tables WHERE owner = 'SCOTT' UNION ALL SELECT view_name FROM dba_views WHERE owner = 'SCOTT' ) LOOP EXECUTE IMMEDIATE 'grant select on scott."' || r.x || '" to scott_reader_role'; END LOOP; END; If you 'grant debug' you should be able to see the source in ALL_SOURCE.

You might also like