Mask specified number of column characters beginning at left. if no value specified the default is 3.

Syntax

/*+  MASK_FIRST(column [, length]) */

Arguments

  • column - name of table column.
  • length - total number of digits to mask, starting at left.

Examples

SELECT MASK_FIRST(name), * FROM widgetcorp.sales.accounts.customers;

| RESULTS | id | name | surname | email |
|---|---|---|---|---|
| XXXie | 39772 | eddie | gaff | egaff@lapd2019.gov |
| XXXe | 23381 | dave | holden | holden.d@turtle.com |
| XXXk | 26354 | rick | deckard | rick@unicorn.co |

SELECT MASK_FIRST(surname, 5) , * FROM widgetcorp.sales.accounts.customers

| RESULTS | id | name | surname | email |
|---|---|---|---|---|
| XXXX | 39772 | eddie | gaff | egaff@lapd2019.gov |
| XXXXXn | 23381 | dave | holden | holden.d@turtle.com |
| XXXXXrd | 26354 | rick | deckard | rick@unicorn.co |