SET HEADING OFF
set FEEDBACK OFF
set pagesize 10000;
SET VERIFY OFF
set lines 300
SELECT 'CREATE OR REPLACE PUBLIC SYNONYM ' || ob1.object_name || ' FOR ' || ob1.owner ||'.'|| ob1.object_name||';'
FROM all_objects ob1
WHERE ob1.owner in ('DBAASS')
AND ob1.object_type in ( 'FUNCTION','MATERIALIZED VIEW','PROCEDURE'
,'SEQUENCE','TABLE','VIEW','PACKAGE')
spool /tmp/create_synonym01.sql
/
spool off
SQL