Masking failure with error "The same column cannot be masked twice"
search cancel

Masking failure with error "The same column cannot be masked twice"

book

Article ID: 415282

calendar_today

Updated On:

Products

CA Test Data Manager (Data Finder / Grid Tools)

Issue/Introduction

The column contains 2 types of data, email and phone.

The masking job failed when tried to mask email and phone data in the same column.

The error message is like,

"The same column cannot be masked twice for table <tablename>"

Cause

The masking configuration is like,

<tablename>,,WHERE,"CONTAINS(<column name>, '@') = 1",,,,,,,,,,,,,,,,,,,,,,,,
<tablename>,<column name>,EMAIL,,,,,Y,,,,,,,,Tag=Phone + Email. Masking Group=Mask phone + email. Mask Function=EMAIL - A random email address.,,,N,,,,,,,,,
<tablename>,<column name>,PHONE_01,,,,,Y,,,,,,,,Tag=Phone + Email. Masking Group=Mask phone + email. Mask Function=PHONE_01 - replace digits 0..9 with digits in parm1 or fixed replacement value.,,,N,,,,,,,,,

 

For masking those rows for phone values, there is no where clause, then the rows to be masked will be overlap with those rows for email, that is the reason of masking failure.

Resolution

Give the where condition for the 2nd mask of the table on the same column, for example,

<tablename>,,WHERE,"CONTAINS(<column name>, '@') = 1",,,,,,,,,,,,,,,,,,,,,,,,
<tablename>,<column name>,EMAIL,,,,,Y,,,,,,,,Tag=Phone + Email. Masking Group=Mask phone + email. Mask Function=EMAIL - A random email address.,,,N,,,,,,,,,

<tablename>,,WHERE,"CONTAINS(<column name>, '@') = 0",,,,,,,,,,,,,,,,,,,,,,,,
<tablename>,<column name>,PHONE_01,,,,,Y,,,,,,,,Tag=Phone + Email. Masking Group=Mask phone + email. Mask Function=PHONE_01 - replace digits 0..9 with digits in parm1 or fixed replacement value.,,,N,,,,,,,,,