table cf column datamask set
Sets the data mask on one or more JSON table columns.
To set a dynamic data mask for a column within a column
family (CF) of a JSON table, use the maprcli table cf column datamask set
command. For columns with existing data, the dynamic data masks will apply to all future
SCAN and GET queries for that table column without any client-side or application changes.
Syntax
- CLI
-
maprcli table cf column datamask set -path <table-path> -cfname <column family name> -name <column-name> -datamask <mask-name>
- REST
-
http[s]://<host>:<port>/rest/table/cf/column/datamask/set?<parameters>
Parameters
Parameter |
Description |
---|---|
path |
The path to the HPE Ezmeral Data Fabric Database table.
|
cfname | The name of the column family of the JSON table field to which the data mask will be added. |
name | The JSON table field. |
datamask |
The name of the data mask. This must be one of the predefined data masks. At most one dynamic
data mask can be set for a specific column at a time. Obtain supported mask names
using the maprcli security datamask
list command. NOTE Using an empty string for a datamask removes
all datamasks from the column family. For
example:
|
Example
- CLI
-
maprcli table cf column datamask set -path /table1 -cfname default \ -name Creditcard -datamask mrddm_last4
- REST
-
curl -X POST \ 'https://r1n1.sj.us:8443/rest/table/cf/column/datamask/set?path=/table1 \ &cfname=default&name=Creditcard&datamask=mrddm_last4' -u <username>:<password>