Using Calculated Fields in a Report Matrix
  • 17 May 2021
  • 2 Minutes to read
  • Dark
    Light

Using Calculated Fields in a Report Matrix

  • Dark
    Light

Article summary

Overview

Calculated Fields transform the values of other fields to create entirely new values. Report Matrixes display a count of how many records match each value reported in a column or calculated column. Each column is referred to as a dimension. Multiple dimensions can be compared along the x- and y-axes of the Report matrix.

Example

For this example, add a calculated column to a Report, configure the Matrix view to include the new column, then run the Report to view.

Prerequisite
The Report Matrix used in this example was created in the Creating and Drilling Down into Report Matrix Data article.
  1. Begin in the Report Designer, expand the Calculated Columns category under Data Fields.

  2. Select the TruncateTextInlineField option and add it to the workspace.
  3. In the resulting Add Calculated Column dialog, configure the calculated column.  This column will display the truncated value of another column.
  4. For this example, configure the column to display the Folder Type Name column's first three letters.  Select Folder Type Name in the Field drop-down list and type “3” in the Limit field. Select OK to finish the calculated column.

  5. The new calculated column, truncate_text_inline_field, appears in the workspace.
  6. Select the Matrix view to edit the existing Matrix.
    To learn how to add a Matrix view to the Report, navigate to Creating and Drilling Down into Report Matrix Data.
  7. When the Matrix view opens, select the Add Dimension link corresponding under the already configured Folder Type Name on the y-axis and select Add Field Dimension.
  8. In the Edit dialog, select truncate_text_inline_field in the Field drop-down list and select SAVE.
  9. Select Run Report in the top action panel in the Report Designer.
  10. The Report will appear in a new window. All of the columns, including the calculated column, will be displayed under the Data icon. Select the Matrix icon to see the Report matrix.
  11. The Matrix view shows the matrix Report and the calculated column that was just added.

Flow Inline Fields Outputs

The output type on a Report can be updated via a Flow to return Integer and Decimal data members. 

  1.  Using the Report mentioned above, navigate to Data Fields and select Add
  2. Navigate to Calculated Columns > FlowInlineField.
  3.  In the Add Calculated Column window, locate and select DATA > PICK FLOW.
  4. In the Create or Pick Flow window, select CREATE to create a new Flow. Name the Flow and select CREATE again.
  5.  In the Flow Designer, connect the Start step to the End step. 
  6.  Navigate to the Properties panel > DATA > Output Type and from the drop down list, select Decimal
  7.  Next, navigate to INPUTS > Output and change the input mapping to Constant. Input a decimal value.
  8.  Save and exit the Flow Designer. 
  9.  In the Report Designer, notice the appearance of the new Data Field with the Constant value.
  10. Select Run Report to view the data in the Report Viewer.

Was this article helpful?