11 Replies Latest reply: Jun 20, 2013 1:07 PM by Dean Gagne-Oracle RSS

    job already exists or invalide argument value error - DBMS_DATAPUMP

    OraFighter

      Below code is running successfully.. but while I run second time  it shows the message 

      ORA-31634 - job already exists

       

      ERROR at line 1:

      ORA-39001: invalid argument value

       

      BEGIN 

      h1 := DBMS_DATAPUMP.OPEN('EXPORT','SCHEMA',NULL,'EXPORT18%U','LATEST');

        DBMS_DATAPUMP.ADD_FILE(h1,'EXPORT18%U.dmp','EXPORT_DIR');

        DBMS_DATAPUMP.METADATA_FILTER(h1,'SCHEMA_EXPR','IN (''SCHEMA_NAME1'')');

        Dbms_Datapump.Metadata_Filter(handle => h1,name => 'NAME_EXPR',value => '!=''CALL_GROUP1_BASE_OLD''', object_type => 'TABLE');

       

      DBMS_DATAPUMP.START_JOB(h1);

       

      dbms_datapump.detach(h1);

       

      END;

       

      first time running successfully... what to do in second time.