I'd like to create ddl scripts for most of my database objects. dbms_metadata.get_ddl works for most of the object types. For instance the following creates the ddl for a view:
select dbms_metadata.get_ddl ( 'VIEW', 'SAMPLE_VIEW') from dual
On the other hand it's not working for object_type 'JOB'. The following:
select dbms_metadata....
Why is dbms_metadata.set_transform_param(dbms_metadata.session_transform, 'CONSTRAINTS_AS_ALTER', TRUE) not generating constraints in separate files? At this moment this pl/sql pastes the constraints after the table schema definition files. What flag do I have to use to achieve this separate constraints schema definition directory?
...
I'm trying to get CONSTRAINTS from user_objects table like this:
select CASE object_type
WHEN 'DATABASE LINK' then 'dblinks'
WHEN 'FUNCTION' then 'functions'
WHEN 'INDEX' then 'indexes'
WHEN 'PACKAGE' then 'packages'
WHEN 'PROCEDURE' then 'procedures'
WHEN 'SEQUENCE' then 'sequences'
WHEN 'TABL...