Running Post Processing Flow On Report OutputLast Updated: 07/15/2016 Introduced in Verision: 3.2
This tutorial demonstrates how to create and use Report Post Processing Flow. This Flow type is used as a Report Output Handler. With this Flow configured, users will get a new option of saving Report into Excel file. In other words, this Flow takes in Report Data and with Steps in the Flow it organizes this Report Data into Excel File. Then, it outputs this custom Excel File. As an example, this kind of Flow may be used in the similar manner as Report Output Template.
In this example we will create a simple Report. Then, we will create a Report Post Processing Flow that will be arranging Report data into Excel File. Finally, we will use this Flow to save our Report as an Excel file.
We begin in the Designer Folder with clicking Create Report/Page > Create Report option from Folder Actions Panel.
In the resulting window we Name our Report and click Create to proceed to the Report Designer.
In the Report Designer we add Account Data Source from Data Sources > Common category.
Next, from the Account Data Source we add desirable columns to populate our Report with data.
This completes our Report for this example. We can save Report and close Report Designer.
Next, in the Portal we navigate to the System > Designers > Report Output > Handlers folder and click Add Report Output Flow button on the Folder Actions Panel.
Then, we Name our Output Handler and click Create to proceed to the Flow Designer.
In the Flow Designer we add Create Data step from the Favorite Steps category.
In the resulting Data Definitions window we click Add New link. Then, in Add Data Definitions window we name our data “File” and define its Type FileData. Click Ok to save and continue.
When our FileData is defined we can click Add to continue.
Then, we select this Create Data on the workspace and Step Information window pops up. We locate Inputs section for the File and select Constant Mapping type. Next, we are going to pick an Excel file from our computer using Path picker.
The Excel file that we are going to pick will serve as a Template for our Report data…
After we picked the Excel File we can click Add Step.
Next, we need to order Report data into the Excel Template using Excel steps in the Flow. We add Set Values In Column step from the All Steps [Catalog] > Data > List > Excel and CSV category.
Next, we select this Set Values In Column step on the workspace. In the Step Information layer we click Show Mapping Editor.
In the Mapping Editor we map data as following…
This step will populate Excel file with data in the first column. For column field we define ‘1’. Define fileType corresponding to the type of our Excel file. For the input field we map our Excel file from the Create Data step. For the row field we define value ‘7’ because first 6 rows in our Excel file contain some data. Finally, for values field we use TextValue collection from ReportData > AllData > Field01. When finished, we can save and close Mapping Editor.
Next, we add another Set Values In Column step from the All Steps [Catalog] > Data > List > Excel and CSV category.
Then, we select this step on the workspace and click Show Mapping Editor in the Step Information layer.
In the Mapping Editor we map data in the similar way that we did for the first Set Values In Column step but this time we define column value ‘2’ and for the values field we use TextValue collection from ReportData > AllData > Field02. Then, we save and close Mapping Editor.
After Steps in the Flow do the work and populate Excel file with data from the Report, we need to update Excel File. We add Update File With Data step from the All Steps [Catalog] > Data > List > Excel and CSV category.
Then, we select Update File With Data step on the workspace and in the Step Information layer locate Inputs configurations. We define fileType and for the input field we use Select Value Mapping type and pick our File data from the Flow.
Next, we connect Update File With Data step to the End Step in the Flow. Select End Step and map our updated File to the Output.
This completes our Flow. We can save it and close Flow Designer.
Then, we locate the Report that we have created at the beginning of this tutorial and Run it.
When Report is running we click Print Report from Report Actions.
In the resulting Print window we select our Report Handler Flow from the Output Type dropdown.
Then, click Download.
Portal prepares Print Preview and we can click Download link…
Then, Decisions informs us that the File was saved. We click Ok…
Next, we locate our Excel File that we just downloaded and it should look like on the following figure…