1

I am trying to create a policy for a column in a database by using below script, which is creating successfully in one data base but in other database it was giving errors.

FYI: Both the databases have EXECUTE PRIVILEGE on DBMS_REDACT POLICY

ORA-28086: The data redaction policy expression has an error.

BEGIN
DBMS_REDACT.ADD_POLICY(
object_schema =>'schemaname', 
object_name =>'tablename', 
column_name =>'columnname', 
policy_name =>'policyneme', 
function_type =>DBMS_REDACT.REGEXP, 
policy_description =>'Masks the first 5 digits of SSN', 
regexp_replace_string =>'XXXXX\3', 
regexp_position =>1, 
regexp_occurrence =>0, 
regexp_match_parameter =>'i', 
expression =>'1=1', 
regexp_pattern =>'(\d\d\d)(\d\d)(\d\d\d\d)'
);
END;
Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Anil Reddy
  • 21
  • 5
  • Thanks Chris do you have any idea about that issue , it's working perfect in all the databases except in one ,Thanks in advance – Anil Reddy Sep 18 '15 at 20:25

1 Answers1

0

This is a bug which is fixed in 12.2

When cursor_sharing=force it will fail with below error ORA-28086: The data redaction policy expression has an error http://oraniltips.blogspot.in/2017/03/ora-28086-data-redaction-policy.html?m=1

nani V
  • 1