ORA-31626 Job Does Not Exist When Using DBMS_DATAPUMP.ATTACH (Doc ID 405745.1)

Last updated on JULY 26, 2016

Applies to:

Oracle Database - Enterprise Edition - Version 10.2.0.2 and later
Information in this document applies to any platform.
***Checked for relevance on 11-Jan-2015***

Symptoms

When you try to use:

h1 := dbms_datapump.attach ('TESTJOB');

from PL/SQL to monitor, for example, an expdp job started from another session like:

#> expdp expdp/expdp dumpfile=x.dmp full=y directory=mydump job_name=TESTJOB nologfile=y

you are getting the following error:

declare
*
ERROR at line 1:
ORA-31626: job does not exist
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 79
ORA-06512: at "SYS.DBMS_DATAPUMP", line 911
ORA-06512: at "SYS.DBMS_DATAPUMP", line 3279
ORA-06512: at line 6

 

Changes

You are trying the PL/SQL block for the second time in the same session.

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms