Using For Each Excel Or CSV Row Step
  • 12 Aug 2022
  • 2 Minutes to read
  • Dark
    Light
  This documentation version is deprecated, please click here for the latest version.

Using For Each Excel Or CSV Row Step

  • Dark
    Light

Article summary

Overview

This tutorial demonstrates how to use For Each Excel Or CSV Row step that can be found in the Toolbox > DATA > EXCEL & CSV categoryIn the following example, a Flow will be created that uses data from an Excel file to create new accounts; the Flow will also show a pop-up notification for each recently created account from the Excel file.

A downloadable example to import into Decisions can be found below. Please navigate to Import and Export Overview for more information on importing a file into Decisions.


Example

  1. Begin in a Designer Folder, and select CREATE FLOW from the Global Action Bar.
  2. In the Create Flow dialog window, select the default Flow, name it For Each Excel Step, and click CREATE to proceed to the Flow Designer.
  3. In the Flow Designer, drag and drop a Create Data step from the Toolbox > FAVORITE STEPS category. Connect this step to the Start step.
  4. In the Properties panel of the Create Data step, select SHOW EDITOR under DATA > Data To Create to define new data.
  5. In the Data Definitions window, Name the data Excel File and select File Data from the Type drop-down list.
  6. Select Edit and drag a relevant Excel or CSV file into the selector. This action will change the input mapping to Constant.
  7. Click CLOSE when complete to save the Data Definition
    In this example, the relevant file can be found below; this excel file will have three columns, including First Name, Last Name, and Email Address.


  8. From the Toolbox > DATA > EXCEL & CSV category, drag a For Each Excel Or CSV Row step into the workspace and connect it to the Create Data step.  


  9. With the For Each Excel Or CSV Row step selected, in its Properties panel > INPUT DATA > Input File Type drop-down list, change the default Excel_xls file type to Excel_xlsxbecause the Excel File has a .xlsx extension. 
  10. Within the INPUTS > File Input value box, change the input mapping from Unknown to Select From Flow and select the output file from the Create Data step. 
    In this example, the File Input will be named Excel File. 


  11. Drag and drop a Create Account step from the Toolbox > SYSTEM > ACCOUNTS category to the workspace and connect it to the For Each Excel Or CSV Row step Next Row outcome.
  12. Change the default input mapping from Unknown to Select From Flow in the Properties panel,  INPUTS > Email Address value boxSelect Current Row, Field03, and Text Value in the resulting dialog.
  13. In the INPUTS > Password value box, change the default input mapping from Unknown to Select From Flow. Select Current Row, Field01, then Text Value in the resulting dialog.

  14. Next, from the Toolbox > FAVORITE STEPS, drag and drop a Show Popup step to the workspace and connect it to the Create Account step. Connect its Done outcome to the For Each Excel Or CSV Row step.
  15. In the Properties panel of the Show Popup step, under INPUTS > Subject, change the default Unknown input mapping to Constant and insert New Account Added into its value box.
  16. The INPUTS > Message will have a Merge Plain Text input mapping.
  17. Select SHOW EDITOR to open the Merge Text Editor dialog, select Current Row > Field03 > Text Value, and input text to reflect information about the new account. 
  18. Select SAVE to close the Merge Text Editor.
  19. Connect the Done outcome from the For Each Excel Or CSV Row step to the End step.
  20. Save the Flow.

Debug

  1. Select Debug from the Top Action Bar. 
  2. Click START DEBUGGING.
  3. Notice the three Popups that appear indicating the newly created accounts were added and that the Flow ended successfully.

Was this article helpful?