Data Pump Import (Impdp) Adds Blank Lines to PLSQL code. (Doc ID 1060772.1)

Last updated on NOVEMBER 28, 2016

Applies to:

Oracle Server - Enterprise Edition - Version: 10.1.0.2 to 11.2.0.1 - Release: 10.1 to 11.2
Information in this document applies to any platform.

Symptoms


TEST CASE
---------

-- Create user schemas
connect / as sysdba

drop user u1 cascade;
create user u1 identified by u1 default tablespace testcase;
grant dba to u1;

drop user u2 cascade;
create user u2 identified by u2 default tablespace testcase;
grant dba to u2;


-- Create procedure
connect u1/u1
drop procedure u1.my_test1;
create or replace procedure u1.MY_TEST1 as
begin
 null;
end;
/



-- Export/Import
expdp u1/u1 DIRECTORY=test_dp DUMPFILE=export_schemas.dmp
impdp u1/u1 directory=test_dp DUMPFILE=export_schemas.dmp remap_schema=u1:u2


-- Original procedure code
SQL> select line, text from dba_source
2 where owner ='U1' and name='MY_TEST1';

LINE TEXT
---------- ------------------------------
1 procedure MY_TEST1 as
2 begin
3  null;
4 end;


-- Procedure code after Expdp/Impdp
SQL> select line, text from dba_source
2 where owner ='U2' and name='MY_TEST1';

LINE TEXT
---------- ------------------------------
1 PROCEDURE "MY_TEST1" as
2 begin
3  null;
4 end;
5             <== Blank line added!



REFERENCE
A very similar issue is described by the following note:

761585.1 -- Data Pump Import (Impdp) adds multiple Blank Spaces (0x20) to PLSQL code.



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