Pick Operator
Overview
The Pick operator retrieves an entire column from a data set using the column's label value key. For example, if a data set has a column with the key value of name in your data table, use a Pick operator with name as the reference key to retrieve that column in your Data Workflow.
You'll find the Pick operator under the Table group to the left of your Data Workflow canvas.
About the Info Window
Learn more about each setting in the Pick operator's Info window:
Setting |
Description |
---|---|
Category |
Grayed out and non-adjustable setting indicating the operation type. |
Label |
Sets the label for your operator, displaying below the operator on your Data Workflow canvas. This field is optional, but set a label if you use more than one of the same operator type. A label helps you identify your operators without opening any Info windows. |
Pick Keys |
This is the reference key leading to the data you want to retrieve. Here, you'll enter the key for the column you want your Pick operator to pull into your Data Workflow. So, if your column has the key name, you'll enter name here. If you're using another operator as an argument, enter _arg here. Keys are case sensitive and must match the capitalization of your column key. |
Adding a Pick Operator
In this example, configure a Data Table component that contains a list of countries. Then, you'll set up a Data Workflow component with two Pick operators. Each operator will retrieve a separate column and output it in a Hidden component.
Configure the Data Table Component
First, you'll set up your Data Table component with a list of countries and their capitals.
1. | In the Module Builder, drag and drop a ![]() |
2. | In the Property ID field, enter dtCountries. |
3. | In the data table, enter the following: |
A | B | |
---|---|---|
1 |
country |
capital |
2 |
Afghanistan |
Kabul |
3 |
Albania |
Tirana |
4 |
Algeria |
Algiers |
5 |
Cambodia |
Phnom Penh |
6 |
Czech Republic |
Prague |
7 |
Andorra |
Andorra la Vella |
8 |
Austria |
Vienna |
4. | Click Save Component. |
Configure the Hidden Components
Before you can add your Data Workflow, you'll need a place to store its outputs. You'll use two Hidden components, each one corresponding to its own Pick operator.
1. | Drag and drop two Hidden components onto your canvas. Place then below the dtCountries ![]() |
2. | In each component's Property ID and Label Text field, enter the following: |
Property ID |
Label Text |
|
---|---|---|
1 |
pickCountry |
pickCountry |
2 |
pickCapital |
pickCapital |
3. | After configuring each component, click Save Component . |
Configure the Data Workflow Component
1. | Drag and drop a Data Workflow component onto your canvas, placing it between the dtCountries ![]() |
2. | In the Property ID field, enter dwfPick. |
3. | In theCanvas Label Text, enter dwfPick. |
Configure the Input Data Operator
1. | Drag and drop anInput operator onto your Data Workflow canvas. |
2. | Configure the Input operator's Info window as follows: |
Info | |
---|---|
Category |
Input |
Component |
dtCountries |
Required |
Yes |
Source |
Default |
Configure the First Pick Operator
1. | Drag and drop a Pick operator onto your Data Workflow canvas. |
2. | Configure the Pick operator's Info window as follows: |
Info | |
---|---|
Category |
Pick |
Label |
Pick Country |
Preserve Argument Type |
☐ (unchecked) |
Pick Keys |
country |
3. | Connect the output port (right) of the dtCountries Input operator to the input port (left) of the Pick Country Pick operator. |
Configure the First Output Operator
1. | Drag and drop an Output operator onto your Data Workflow canvas. |
2. | Configure the Output operator's Info window as follows: |
Info | |
---|---|
Category |
Output |
Component |
pickCountry |
Action |
value |
3. | Connect the output port (right) of the Pick Country Pick operator to the input port (left) of the pickCountry Output operator. |
Configure the Second Pick Operator
1. | Drag and drop a second Pick operator onto your Data Workflow canvas. |
2. | Configure the Pick operator's Info window as follows: |
Info | |
---|---|
Category |
Pick |
Label |
Pick Capital |
Preserve Argument Type |
☐ (unchecked) |
Pick Keys |
country |
3. | Connect the output port (right) of the dtCountries Input operator to the input port (left) of the Pick Capital Pick operator. |
Configure the Second Output Operator
1. | Drag and drop a second Output operator onto your Data Workflow canvas. |
2. | Configure the Output operator's Info window as follows: |
Info | |
---|---|
Category |
Output |
Component |
pickCapital |
Action |
value |
3. | Connect the output port (right) of the Pick Capital Pick operator to the input port (left) of the pickCapital Output operator. |
4. | Click Save Component. |
Here's how the completed Data Workflow looks:
Configure the Button Component
Lastly, create a button to click in Express View that triggers your Data Workflow.
1. | Drag and drop a ![]() |
2. | In the Property ID field, enter btwRunDWF. |
3. | In the Label Text field, enter Run DWF Pick. |
4. | Navigate to the Actions settings. |
5. | From the Action Type drop-down, select Event. |
6. | In the On Click field, enter or select dwfPick. |
7. | Click Save Component. |
8. | Save your module. |
Here's how the completed configuration looks in the Module Builder:
Preview your module in Express View and click Run DWF Pick. The Data Workflow uses the Pick operator to send each column data set to its respective Hidden component. The DevTools Console displays the following: