Loading
Salesforce Enforces New Security Requirements in Summer 2026Read More
Sandboxes: Staging Environments for Customizing and Testing
Creating Masking Filter Conditions

Creating Masking Filter Conditions

Add conditions to object record filters to narrow masking job results.

Required Editions

Available in: Lightning Experience
Available in: Professional, Enterprise, Unlimited, and Developer Editions with the Salesforce Data Mask add-on license.
User Permissions Needed
To create a masking filter conditions:
  • Data Mask And Seed User Permission Set License
  • Data Mask And Seed User Permission Set

In the Filter Records dialog, when you select a filter condition field (Add a Filter field), a secondary dialog opens where you define the condition using the Field, Operator, and Value fields, as follows:

  • Field: Select the object field to filter on, such as BillingState or AnnualRevenue
  • Operator: Select a comparison operator, such as, Equals, Is NULL, or Greater or equal
  • Value: Enter one or more values to compare against. For example, for operator Equals and the BillingState field, enter CA or for operator Greater or equal and the AnnualRevenue field, enter 1000000. For operators like Is NULL or Is not NULL, the Value field disappears because no value is needed. When entering multiple values, separate each of them with a comma.
Important
Important Data Mask & Seed can filter encrypted object fields when the field's data (the field's Value) is protected with Shield Platform Encryption using deterministic encryption (and not Shield Platform Encryption's probabilistic encryption).

Select Apply to save the filter condition. The secondary dialog closes and the condition appears in the Filter Records dialog.

Select Save in the policy page, to save your updates. Unsaved changes are lost when you navigate away.

Filter Example: Filter Accounts in California with High Revenue

To mask only account records (policy object Account) that are located in the Canadian province of Ontario and that have an annual revenue greater than $3.5M:

  1. Set Filter Logic to “All conditions are met (AND)”
  2. Add the first condition:
    1. Field = "BillingState"
    2. Operator = "Equals"
    3. Value = "ON"
  3. Add the second condition:
    1. Field = "AnnualRevenue"
    2. Operator = "Greater or equal"
    3. Value = "3500000"
  4. Select Apply for each condition, then select x to close the dialog
  5. In the policy page, select Save to save your added object filter

Edit Filter

To edit an existing filter, open the policy in Edit mode and select Edit Filters. In the Filter Records dialog, you can:

  • Modify a filter condition - select the condition to open the secondary dialog. Change the Field, the Operator, or the Value, then select Apply
  • Delete a filter condition - select the garbage can icon located to the right of the condition field
  • Add a filter condition - select + Add Filter and define the new condition as described above in Add Filter Condition

Select Save in the policy page, to save your updates. Unsaved changes are lost when you navigate away.

 
Loading
Salesforce Help | Article