FLASHBACK_TIME With DataPump API Reports ORA-39001 (Doc ID 941974.1)

Last updated on NOVEMBER 28, 2016

Applies to:

Oracle Database - Enterprise Edition - Version 10.1.0.2 and later
Information in this document applies to any platform.
***Checked for relevance on 08-May-2013***

Symptoms

You created the following PL/SQL block to start an export job using the DataPump API:

declare
  h1 NUMBER;

begin
  h1 := dbms_datapump.open (operation => 'EXPORT', 
                            job_mode  => 'TABLE');

  dbms_datapump.add_file (handle    => h1, 
                          filename  => 'TEST.DMP', 
                          directory => 'DATA_PUMP_DIR', 
                          filetype  => 1);

  dbms_datapump.add_file (handle    => h1, 
                          filename  => 'TEST.LOG', 
                          directory => 'DATA_PUMP_DIR', 
                          filetype  => 3);

  dbms_datapump.metadata_filter (handle => h1, 
                                 name   => 'SCHEMA_EXPR', 
                                 value  => 'IN (''SCOTT'')');

  dbms_datapump.metadata_filter (handle => h1, 
                                 name   => 'NAME_EXPR', 
                                 value  => 'IN (''EMP'')');

  dbms_datapump.set_parameter (handle => h1, 
                               name   => 'FLASHBACK_TIME', 
                               value  => '10-09-2009 09:45:00');

  dbms_datapump.start_job (handle => h1);

  dbms_datapump.detach (handle => h1);
end;
/


You intend to export the table EMP from schema SCOTT as seen at time 10-09-2009 09:45:00. If you run the anonymous PL/SQL block, then the following error stack is raised:

declare
*
ERROR at line 1:
ORA-39001: invalid argument value
ORA-06512: at "SYS.DBMS_SYS_ERROR", line 79
ORA-06512: at "SYS.DBMS_DATAPUMP", line 2926
ORA-06512: at "SYS.DBMS_DATAPUMP", line 3162
ORA-06512: at line 7


You verified the definition of directory DATA_PUMP_DIR and the privileges and these are correct.

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