My Oracle Support Banner

How To Specify Multiple Roles in DBMS_REDACT.ADD_POLICY Procedure Expression Parameter Using SYS_CONTEXT(''SYS_SESSION_ROLES'') in For Oracle Data Redaction (Doc ID 2420366.1)

Last updated on AUGUST 04, 2018

Applies to:

Oracle Database - Enterprise Edition - Version 11.2.0.4 and later
Information in this document applies to any platform.

Symptoms

While creating a new or modifying existing Data Redaction policy using DBMS_REDACT.ADD_POLICY or DBMS_REDACT.ALTER_POLICY,  How to specify multiple roles using SYS_CONTEXT(''SYS_SESSION_ROLES'') for expression attribute.

e.g. how to add verification of multiple session roles for the following policy syntax:

 

In the above syntax "expression => 'SYS_CONTEXT(''SYS_SESSION_ROLES'',''ROLE_DEL'') = ''FALSE'''" will validate that a role "ROLE_DEL" is not enabled in user session, If the policy has to be applied. However in the above syntax onle one role is verified.

How can multiple roles like ROLE2, ROLE3 be included in the same policy expression?

Changes

 A new Data Redaction policy is being created.

Cause

To view full details, 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 a vibrant support community of peers and Oracle experts.