CSV To List Mapping Step
  • Updated on 09 Apr 2019
  • 3 minutes to read
  • Print
  • Dark
    Light

CSV To List Mapping Step

  • Print
  • Dark
    Light

This tutorial demonstrates how to convert data from Excel Document to a Simple List of Strings using CSV To List Mapping step from Integration > Excel and CSV category in the ToolBox .

Example:
We begin in the Designer Folder with clicking Create Flow button on the Folder Actions panel.

2018-08-14_150526-1.jpg

Next, we Name the Flow and click Create to proceed to the Flow Designer.

2018-08-16_152739.jpg

In the Flow Designer we add Create Data step from All Steps [Catalog] > Data category in the Flow Designer Wizard.

2018-08-16_152956.jpg

In the resulting Edit Step pop-up window select Add New link to create new Data .
In the Add Data Definitions window Name our Data Definition and define its Type as FileData .
Our Data Definitions should look like following. Select Close to save and close.

2018-08-16_153216.jpg

Then, we add CSV To List Mapping step from All Steps [Catalog] > Integration > Excel and CSV category in the Flow Designer Wizard.

2018-08-16_153714.jpg

Next, we are going to pick an Excel Document for our Flow . The Excel Document for this example looks as follows:

2016-12-14_083538.png

To add this Excel Document to our Flow we select Create Data step on the work space. Within the Edit Step dialog locate the Inputs section, and select the Excel Document using Choose File for our File Data Definition.

2018-08-16_154424.jpg

Next, select CSV To List Mapping step on the work space. Within the Edit Step dialog define its Output Type as String .

2018-08-16_154905.jpg

In the Inputs section for the CSV To List Mapping step we choose Select Value from the Mapping type dropdown for InputFile .
Then, use Path picker to map InputFile to the File Data Definition from Create or Copy Data Step.

2018-08-16_155515.jpg

Next, select Show Item Mapping Editor option from CSV To List Mapping step’s Properties Toolbox.

2018-08-16_160023.jpg

In the Item Mapping Editor use Merge Plain Text mapping type for the ITEM field.
Then select Show Editor button to create Merged Text.
Our completed Text Merge should look as following for this example… When finished, close Text Merge Editor . Then, save and close Item Mapping Editor.

2018-08-16_160228-1.jpg

Back in the Flow Designer we need to create a Form to display data from CSV To List Mapping step. We add Show Form step from Favorite Steps in the Flow Designer Wizard.

2018-08-16_161013.jpg

In the resulting dialog Name our Form and click Create to proceed to the Form Designer.
2018-08-16_161139.jpg

In the Form Designer, add Button control component from Actions category in the ToolBox for our Form to have at least one Outcome .
Then, add List Box component from Data category in the ToolBox .
Configure our List Box component as following. Define List Items Data Name and Type of String in theInput Data section**.** This completes our Form Design . Save our Form and close Form Designer.
2018-08-16_161911.jpg
Figure 13: List Box Input/Output Data

Back in the Flow Designer we connect our Form step to the End Step on the workspace. Then, we call Mapping Editor for our Form step to map Simple List component to the data it should display.
2018-08-16_162649.jpg
Figure 14: Edit Input Mapping

In the Mapping Editor, connect the List component to the OUTPUTS outcome fromCSV To List Mapping step. Then, Ignore theMapping type for the Selected Item in the List field. Select Ok to save and close Mapping Editor.
2018-08-16_162907.jpg
Figure 15: Input Mapping: Show Form

Connect the Show Form Step to the End Step, the flow is complete. SelectDebug from the Top Panel in the Flow Designer to test the Flow .
2018-08-16_163041.jpg
Figure 16: Debug

The Display Form opens in the Debugger. Observe that the List component displays Data from the Excel Document as it was designed in CSV To List Mapping step. Select the Button on our Form in the Debugger to close the Form .
2018-08-16_163509.jpg
Figure 17: Show Form in Debugger

Flow Diagram Tab in the Debugger indicates that our Flow ran to the End Step with no errors.
2018-08-16_163557.jpg
Figure 18: Complete Flow

Was this article helpful?