2 thoughts on “DBMS_DATAPUMP – why quote delimiters are your friend

  1. How do you exclude the jobs?
    Below is the sql and if my source schema has values on this and I need to skip it for the exp, thanks
    select owner from dba_scheduled_jobs

    • Dennis,

      If you look in database_export_objects, there are some paths that refer to JOBS :

      select *
      from database_export_objects
      where object_path like '%JOB%
      /
      
      OBJECT_PATH				 COMMENTS
      ---------------------------------------- ----------------------------------------
      JOB					 Jobs in the selected schemas
      SCHEMA_EXPORT/JOB			 Jobs in the selected schemas
      

      So, assuming you want to exclude all of the scheduler jobs from a schema export, something like this might do the job :

      dbms_datapump.metadata_filter
      (
          handle => the_datapump_job_handle,
          name => 'EXCLUDE_PATH_EXPR',
          value => q'[= 'JOB']' 
      );  
      ...
      

      HTH,

      Mike

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s