Query to get the DDL of DB objects in Oracle

0

select dbms_metadata.get_ddl('TABLE','WC_CUSTOM_DIM_DS','GBBIAPPS2_DW') from dual;

select 'select dbms_metadata.get_ddl(''TABLE'','||''''||table_name||''','||''''||owner||''') from dual union all' from all_tables where owner='INFOREP' and table_name like 'LEVEL1%'