Pattern Variance Type
Use Pattern Variance to mask an input substring with a specific pattern.
Set the options to alter input data based on a pattern variance type (preserve, character, string, or default).
| Option | Description |
|---|---|
| Substring definitions |
Choose the type of pattern variance. Character: Masks the defined substring by randomly replacing each of the characters in the defined substring with values that you specify in the Value field. Retains spaces and special input characters in the output field. Preserve: Outputs the defined substring the same as it is input. String: Masks the defined substring by randomly replacing the entire substring with values that you specify in the Value field. Does not retain spaces or special input characters in the output field. Default: Masks each applicable character with like characters for alpha and numeric content. Retains any special input characters and spaces in the output field. |
| Starting position |
Specify the starting position for the substring by using the beginning slider. The application includes each alpha, numeric, space, and other printable character (special characters such as @, #, _, &) in the position count. For example, if you have the phone number value 555-123-4567 ext. 1212, then the entire string has 22 characters because it includes the 2 hyphens, 2 spaces, 3 letters, 14 numbers, and one period. The default starting position is 1. |
| Ending position |
Specify the number of positions (characters) to include in the substring by moving the ending slider. Leave the slider all the way to the right to randomize the mapped input field from the set starting position to the end of the string. For example, set the Length to 2 for a two-character substring. If the starting position is set to 5, the substring consists of position 5 and 6 of the specified input field. Leave the slider all the way to the right in this example to mask all positions starting at position 5 through the end of the string. |
| Value |
Available on Character and String definitions. Specify alpha and numeric characters, spaces, and special characters for masking the substring. The values you enter must comply with the pattern variance type you choose. For example, when you choose the string pattern variance type, enter alpha or numeric strings or numeric ranges. String pattern variance does not accept alphabetic ranges. You may include more than one value. Single value: Varies the output based on the value specified. Value range: Varies the output based on the minimum and maximum values specified. |
Example
Default variance type
The following table describes how the default pattern variance masks input characters with like characters.
| Input character type | Mask values |
|---|---|
| Alphabetic |
Masks lower-case alpha character with random lower-case alpha character Masks upper-case alpha character with random upper-case alpha character |
| Numeric | Masks each numeric character with a random numeric character from 0 up to and including 9. |
| Special characters or spaces | Does not mask special characters or spaces, but outputs them as they are input, unmasked. For example, when the input substring contains a dash (-), the default pattern variance keeps the dash in the output. When the input substring contains a space, the default pattern variance keeps the space in the output. |
The following table shows the best practice use of default pattern variance.
| Description | Best practice | Example |
|---|---|---|
| Mask an entire input field using the default pattern variance. | Add a substring definition with a Default variance type. |
Starting position: 1 Ending position: <slider all the way to the right> |
| Automatically apply the default pattern variance to substrings of a mapped input column that are not defined. | Define input field substrings using one or more of the other pattern variance types, and leave portions of the input value undefined. |
Definition 1: Definition type: Preserve Starting position: 1 Ending position: 3 Definition 2: Definition type: String Starting position: 4 Ending position: 5 Value range min-max: 20-25 Undefined range: 6-end of the value Results Definition 1: Preserves the characters in positions 1-3 Definition 2: Masks the entire substring (position 4-5) with a number that is included in the minimum/maximum range (in this case 20-25) Undefined: Masks position six to the end of the field with the default pattern variance. |
Example
Preserve variance type
The following table contains an example of the preserve pattern variance.
| Strategy | Settings | Example input/output | Notes |
|---|---|---|---|
| Preserve the unit identification number in each record. Mask the rest of the value with the default pattern variance. |
Undefined: character in position 1 Definition: Definition type: Preserve Starting position: 2 Ending position: 3 Value: <blank> Undefined: characters 4 through the end of the value |
Input value: B12:G350 Possible output values, preserved characters in bold. A12:N799 F12:M127 |
Undefined: Masks the first position with a like character using the default pattern variance. Definition: Preserves position two and three with the preserve pattern variance. (In this case the numbers 12). Undefined: masks the fourth position to the end of the string using the default pattern variance. The colon in the input field (character four) is included in the undefined portion. The software outputs the colon as it was input based on the default pattern variance definition. |
Example
Character variance type
The application masks each character in the defined substring with a character from the Value option.
Special characters are output as they are input, without masking them, when they are present in a defined substring for character pattern variance.
The following table contains an example of the character pattern variance.
| Strategy | Settings | Example input/output | Notes |
|---|---|---|---|
| Mask an identification code with specific alpha or numeric values, and apply the default pattern variance to the remaining portion of the value. |
Undefined: character in position 1 Definition: Definition type: Character Starting position: 2 Ending position: 3 Value: J-L|B|W-Y|2 Undefined: characters 4 through the end of the value |
Input value: 123a Possible output values, masked characters in bold. 8KBx 32Wt |
Undefined: Masks the first position with a like character using the default pattern variance. Definition: Masks position two and three using the character pattern variance and randomly chooses a character specified in the Value field to mask each position. Undefined: Masks the fourth position to the end of the string using the default pattern variance. |
Example
String variance type
The application masks the entire defined substring with a random character or string from the Value option.
The Value option can include one or more alpha or numeric characters (such as “MILK” or “2458”), spaces, special characters (such as @, #, _, &), numeric ranges, or any combination of these in a list in the Value option.
The application counts all alphanumeric characters, spaces, and special characters when it determines the substring length. However, the application does not retain the special characters or spaces in the output when they are present in a defined substring for string pattern variance.
The following table contains an example of the string pattern variance.
| Strategy | Settings | Example input/output | Notes |
|---|---|---|---|
| Preserve the product code, but mask the type of milk (white, chocolate, soy, and so on) with the general term MILK. |
Definition 1: Definition type: Preserve Starting position: 1 Ending position: 5 Value: <blank> Definition 2: Definition type: String Starting position: 6 Ending position: <end of column> Value: MILK |
Input value: 5428-WTMLK 5429-SOYMLK Possible output values, string characters in bold. 5428-MILK 5429-MILK |
Definition 1: Preserves the first through the fifth positions, including the dash, as part of preserve pattern variance. The dash is output as it was input because it is included in the preserve pattern variance. Definition 2: Masks position six to the end of the field with the value “MILK”. |
| Include a zero to the left of any number in a range (to the left of the lower or higher number or to both numbers) so the mask value is left-padded with zeros for the length of the substring. |
Definition 1: Definition type: String Starting position: 1 Ending position: 5 Value: 01-8|999 Undefined: position 6 through the end of the column. |
Input value: 04-a1099 Possible output values, string characters in bold. 00003502 999832 |
Definition 1: Outputs the first through the fifth characters with a number from 1 up to and including 8, or the number 999. When the application chooses a number from the range as a mask value, it zero-pads the number to the left so the masked value is the length of the defined substring (5 characters). The application does not zero-pad the number 999 because it does not contain a leading zero in the Value option. The application includes the dash in the input field in the position count for the substring. However, the application does not output the dash as part of the string pattern variance definition. Undefined: The application applies the default pattern variance to the undefined portion of the input field, character six to the end of the field, and replaces each numeric value with a random value from 0 to 9. |
