Loading
Salesforce now sends email only from verified domains. Read More
Own from Salesforce
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Custom Field Replacement Values in Anonymize Templates

          Custom Field Replacement Values in Anonymize Templates

          Custom value generation gives you more control to create unique values that comply with regulations or testing prerequisites. Using custom values helps prevent errors when the automatically generated values don't comply with your business logic.

          Per object field in your anonymization template, the Replace with drop-down menu's Custom option provides you the ability to define a custom pattern that Anonymize processing uses to generate a custom replacement value for that object field. With custom values, you can create a specific date, a date range, a number range, or an email address pattern.

          Own's anonymization template anonymizes potentially sensitive data by replacing record fields' values with values from a library of alternative, yet representational options for each field. Use the anonymization template's custom option to define and control the formula for generating replacement values.

          The Replace with drop-down menu's Custom option is available for object fields of the following field types:

          • Currency
          • Date
          • Email
          • Number (Decimal, Double, Int)
          • Percent
          • Phone
          • Picklist
          • String
          • Text Area
          • URL

          Custom Block Options

          Each option is a building block that can be used on its own, in combination with other blocks, or used multiple times. The available blocks are:

          • Library: Drop-down list of fake automatically generated value types.
            • For example, to create a string containing fake names.
            • These are the same values available outside the custom option, that can also be used to define your customize pattern.
            • Combine Library blocks with other blocks (e.g. List, Free Text, Number Range) to create the desired pattern. For example, to verify the generation of 1.5M unique value:
          • List: Creates a predefined list of values. Anonymize randomly uses the values entered in the list.
            • For example, to create an email name with a fixed domain and list of top-domain name options to be selected.
            • Add values by entering them in the pane. Clicking outside the pane saves the updates that you made.
            • You can paste into the pane multiple, comma-separated values that were copied from any of the following file types: csv, Excel, and plain text.
            • For object fields of type Picklist, List is the block that is used to customize replacement values. The Custom Replacement Value dialog opens in List block mode. There is no option to add blocks - neither repeating the same block nor combining with other blocks. The dialog displays the field's existing picklist values. Update these values (add/delete) as needed.
            • Salesforce doesn't allow adding new values to restricted picklists. Therefore, avoid adding new values to restricted picklists, as doing so will result in a Salesforce processing error.
          • Free Text: Enter any value. If you use only the Free Text block, all your records have the same value.
            • For example, to create a phone number with the prefix: 1-800-xxx-xxx.
            • Free text can be used as a unique value for all records or as part of the custom pattern.
            • Combine with other building blocks. For example, generate emails with the domain: “@example.com”.
          • Number Range: Select the highest and lowest values within a set of numbers. You can use negative numbers. The options:
            • Random - Randomly generate numbers within the defined number range.
              • For example, if the number range starts with number 1 and ends with number 999, the random numbers are: 3,77,32,876,77,554.
            • Consecutive - generate numbers that are consecutively ordered within the defined number range
            • Trailing numbers - Ordered sequence of consecutive numbers within the defined range.
              • For example, if the number range starts with number 1 and ends with number 999, the trailing numbers are: 1,2,3,4,5...999.
            • You can also select to use leading zeros to give all numbers the same number of characters as the maximum number value. For example, to create a 3 digit value between 1-100, check the leading zero option to generate 001, 002...099, 100, instead of 1,2...99, 100.
            • Base - define the number base to use when generating the range of numbers. The base options are:
              • Decimal (default selection) - generate base 10 numbers
              • Hexadecimal - generate base 16 numbers
            • Range - define both the starting and ending numbers of the generated range of numbers. The Start - End range limit per base is as follows:
              • Decimal: 1 - 1000000 (default Start - End entries)
              • Hexadecimal: 1 - F4240 (default Start - End entries). Note: Hex F4240 = decimal 1000000
            • To build a number pattern with unique values, create a pattern with multiple number ranges. To generate the greatest number of unique values, select the Random option in all ranges.
          • Existing Value: Use a field's existing value either exactly as is or by modifying the field's value. A dialog provides you with the following, optional, field value treatments:
            • Use the Existing Value (default selection): Select to use the field's value as is (no change to field's value).
              • Use case: Add to the field's existing value either a prefix, a suffix or both. For example, generate a custom replacement value that appends the suffix .invalid to an email address.
            • Use only First/Last <####> characters: Select and specify the use of either only the first or only the last <number of> characters of the field's existing value (field's value modified)
            • Use all before <Type...>: Select to use all of the characters of the existing value that occur before the character pattern that you specify (field's value modified).
              • Use case: Replace the email address xxx@salesforce.com with xxx@owndata.com by combined use of both the Existing Value building block using the option Use all before @salesforce.com plus the Free Text building block that provides the text @owndata.com.
            • Existing Value is available for use with the following object field types:
              • Email
              • Phone
              • String
              • Text Area
              • URL
          • Characters: The Characters value type category (custom pattern building block) provides you with the ability to generate a random character string for use as a custom replacement value to anonymize the selected field's existing value. Choosing this custom pattern building block opens the Character String dialog from which a user specifies the requirements that the Anonymize application uses to generate the random character string for the field:
            • Number of Characters category (user chooses a single option):
              • Same as exists in field (default selection) - generate the same number of characters as exists in the selected field.
              • Specify number <####> - specify the number of characters you want generated.
            • Character Types category (user can choose a single option or can choose multiple options):
              • Alphabetic - lowercase (default selection)
              • Alphabetic - UPPERCASE (default selection)
              • Numeric (default selection)
              • Special characters (any of the following: ! @ # $ % ^ & * ( ) _ + [ ] | ; : , . < > ? ` ~ )

              When choosing multiple Character Type options, the generated, random character string can include any of the following types of characters:

              • Some of the chosen character types
              • All of the chosen character types
              • Only a single character type

          Multiple Selection - Custom Option

          You can select multiple fields of the same type and set a single custom value across all those fields.

          If the generated pattern for a single field is longer than the maximum number of characters allowed, the value is truncated accordingly for that field.

          When you select more than one field, a dialog box appears showing the number of fields selected, the field type and the Replace with options. From the Replace with drop-down menu, select Custom..., the Custom Replacement Value dialog opens. Click the plus icon to select the building blocks you need and begin defining your custom pattern.

          Custom Pattern Processing Considerations

          • For numbers, phone numbers, URLs, and email addresses, spaces are automatically removed from the generated values.
          • The Custom Replacement Value (<field name>) dialog displays a bullet item that states the Salesforce maximum number of characters permitted for that field. Additionally, certain building block dialogs also present this information for the field being addressed. For example, for the PersonEmail field, the Free Text dialog displays in its bottom right corner the <number of characters currently entered>/80, where 80 is the field's maximum character limit. If the generated pattern exceeds the field maximum, the value is trimmed to the maximum permitted.
          • When creating email addresses or URLs, make sure that the custom pattern you define is valid, as the Anonymize application does not validate the generated result for either email addresses or URL formats.

          Custom Replacement Values Best Practices

          UNIQUE Anonymized Values

          • Using the Custom... option, you can concatenate numbers to an anonymized value and use the Free Text building block and/or the Number Range building block to make the anonymized value unique. For example, generate 1 million unique names by creating the following pattern:
            • Click the plus icon , select the building block Library and, from the drop-down menu, select the Replace with option Full name.
            • Click the plus icon, select the building block Number Range and, in the dialog, select the Base option Decimal, select the Ordering option Consecutive, keep Range Start and End default values of 1 and 1000000 respectively.
            • When creating a pattern with multiple number ranges, then to both build a number pattern with unique values and generate the greatest number of unique values, use multiple Number Range building blocks. In each Number Range dialog, select the Ordering option Random.
            • To build a DATE pattern, the date format is: YYYY-MM-DD. For example, generating a birthdate for people ages 20 and below, create the following pattern using three Number Range building blocks, corresponding to the year value (YYYY), the month value (MM) and the day value (DD), and two Free Text building blocks that provide the date format's required dashes ( - ), placing one after the year value and placing the other after the month value.
          • Use Custom Values in Anonymization Templates
            Define custom anonymization patterns when masking data to replace sensitive information with realistic, yet fictitious, data. Create custom patterns across multiple fields for data such as email addresses, phone numbers, or social insurance numbers.
           
          Loading
          Salesforce Help | Article