11g Data Pump – Data Obfuscation
lData Obfuscation
lDuring export or import operation
lModify data via PL/SQL routine
lRemap_data parameter
lLists schema.table_name.column_name:
package_name for remap operation
lSeparate remap_data parameter for each
table/column pair.
11g Data Pump – Data Obfuscation
lExample PL/SQL Code.
Create or replace package my_package
as
function my_function (p_in_data varchar2)
return varchar2;
end;
/
Create or replace package body my_package
as
function my_function (p_in_data varchar2)
return varchar2
As
v_return varchar2(30);
begin
v_return:=translate(p_in_data, 'abcdefghijklmnopqrstuvwxyz',
'bcdefghijklmnopqrstuvwxyza');
return v_return;
end;
end;
/
Remap during import (with 2 columns)
impdp Robert/robert DIRECTORY=data_pump_dir
DUMPFILE=remap.dmp tables=RAJ.NAMES
remap_data=RAJ.copy_names.user_name:
RAJ.my_package.my_function
remap_data=RAJ.copy_names.user_commment:
RAJ.my_package.my_function
lData Obfuscation
lDuring export or import operation
lModify data via PL/SQL routine
lRemap_data parameter
lLists schema.table_name.column_name:
package_name for remap operation
lSeparate remap_data parameter for each
table/column pair.
11g Data Pump – Data Obfuscation
lExample PL/SQL Code.
Create or replace package my_package
as
function my_function (p_in_data varchar2)
return varchar2;
end;
/
Create or replace package body my_package
as
function my_function (p_in_data varchar2)
return varchar2
As
v_return varchar2(30);
begin
v_return:=translate(p_in_data, 'abcdefghijklmnopqrstuvwxyz',
'bcdefghijklmnopqrstuvwxyza');
return v_return;
end;
end;
/
Remap during import (with 2 columns)
impdp Robert/robert DIRECTORY=data_pump_dir
DUMPFILE=remap.dmp tables=RAJ.NAMES
remap_data=RAJ.copy_names.user_name:
RAJ.my_package.my_function
remap_data=RAJ.copy_names.user_commment:
RAJ.my_package.my_function
No comments:
Post a Comment