Action View Template - Formula Fields

Here is a description of the interface elements on the Action View Template - Formula popup. This popup displays when you click the Formula icon on the Columns tab on the Action View Template page. The Formula icon is only available when Type=Formula. See Building Formulae for Use in Action Views for examples.

Build the formula that you want to apply in this column by dragging its components onto the drop zone. Drag a Number, Field, or Column icon to the drop zone, then supply the value you want to use with that component:

Components
Component Value to Supply
Number The numeric value you want to use in the formula.
Field The numeric field you want to use in the formula. Only numeric fields that have been included in the dataview are available for use in formula columns.
Column The presentable column you want to use in the formula. This can be any presentable column that has been added to the action view template, but must be a filtered column or other formula.

Drag the operators into the expression to complete your formula. The operators available are:

  • + Add
  • - Subtract
  • * Multiply
  • / Divide

Drag parentheses ( ) into the formula to ensure the formula is calculated correctly. Items within parentheses are calculated first, followed by multiplications and divisions. For example, if you calculate the average weekly spend over the first two periods, you need to use parentheses as shown:

Example of parenthesis use in formula

The formula below is incorrect in this case because it adds the value Actual001 to the result of dividing Actual002 by 8.

Example of incorrect formula (no parenthesis)

Note:

If the value of a numeric field used in a formula is NULL, it is treated as zero when the operator is Add or Subtract.

You can remove items from the formula by dragging them up to the Trash Can area at the top of the popup screen. You can also rearrange the formula by dragging items and dropping them elsewhere within the expression.

Fields
Field Description
Decimal Places to Calculate To The number of decimal places that the formula calculates to. If you also want the calculation to be displayed to this number of decimal places, change the Decimal Places value on the Action View Template - Column Formatting popup for this column. Any other formatting rules specified on the Action View Template - Column Formatting popup are applied when displaying the calculation in the results grid.

You can use the following buttons to perform actions.

Buttons
Button Description
Cancel Closes the popup without applying the changes.
Clear Clears the current formula.
Reset Resets the formula to how it was when you opened the popup.
OK Applies the current formula and closes the popup.