The Generate items masking activity allows you to generate items of the selected type from the collection of items in the defined order.
|Table of contents|
To use the Generate items masking activity, it must be placed inside a table masking activity or a similar activity that iterates over data. Once placed, select the property you want to mask and create a new instance of the generator that uses values from the collection of items, that are going to be assigned to the selected property in the order as they are written.
Additionally, you can set the EnforceUnique property to make sure every assigned item is unique. This option must be used with care so that the number of table records is not greater than the possible items in the defined range.
In this example we want to assign an item from the defined collection to the first 8 table records of the Address table. First, we place the Address masking activity into opened Package.xaml and put the Generate items masking activity within it. Then select the type of the items that are going to be used:
Figure 1: Select Type window
Once placed, we select the Number property that we want to mask with generated items. In Items field enter
Figure 2: Generating items
Modify Filter property to mask only first 8 table records:
|Property group||Property name||Description||Example|
|Input properties||DataItemProperty||The property to mask.||Choose property from the dropdown list|
|EnforceUnique||If true, random selection should select unique values.||
|Items||Collection of items used to generate values.||
|Input: Filter||Filter||Expression used for filtering records - only filtered items will be masked.||
|SkipDefaultValues||If true, default values will be omitted in masking (i.e. null values are not masked).||
|Input: Repeating||RepeaterId||The ID of the repeater that will be used to detect repeating and save results when masking item key repeats.||
|RepeatingKey||Key to use for repeating detection.||Write
|Misc||DisplayName||Display name of the activity in the workflow.||
|Result||Contains the masking definition object. It's a part of the masking infrastructure and should be ignored.||-|