Help Center

| Submit or View Help Requests | Developer Docs |

View desktop instructions
View mobile app instructions
Set Up a Calculated Field

Calculated fields enable you to track events as they come in, set up a calculation using event fields, and store the resulting data on a participant’s profile. Once the calculated field is set up, its value will update dynamically as you send impact.com events that meet your criteria.

This guide will show you the basic process for setting up a calculated field, including an example at the end. For more details about how calculated fields work and what types of calculations are possible, refer to Calculated Fields Explained.

Set up a calculated field

  1. From the left navigation menu, select Data Sources → Fields.

  2. Select Create calculated field.

  3. Complete the fields:

    • Name

    • Event

    • Calculation

    • Event field (if applicable for your calculation)

  4. Optionally, apply a Tracking Window if you want to perform a sum or count calculation on a rolling basis. The time zone for your impact.com account will apply to the tracking window.

  5. If you applied a sliding window, then you can set a maximum value to be counted for each unit of your interval (e.g., each day in a 60 day interval).

  6. In the Filters field, add an Active Period if you want to set a start and end date for the calculation.

  7. Select plus-circle-solid__1_.svg Additional filters if you only want events that meet specific criteria to be included in the calculation.

    • Filters can apply to event characteristics (e.g., revenue amount for a given purchase) or user characteristics (e.g., a count of the number of times a participant makes a purchase over $100)

  8. Review your selections and decide if you want to backfill the values for all participants.

    • Select the check-square-solid__2_.svg [Checked box] if you want to backfill calculations.

  9. Select Save to have your changes saved.

Example

  • You have a referral program and want to reward participants who frequently make sizable purchases soon after they’ve been referred. You determine that for your program, this means any participant who makes 3 or more purchases of at least $50 in the month after the referral starts. A calculated field can help you determine which of your participants meet this threshold and act as the basis for a program rule that issues these participants a reward.

    Setup instructions

    Here’s how the calculation can be set up:

    1. Under the Calculation, complete the Name field.

    2. Enter the following values for the event and calculation fields:

      • Event: Purchase

      • Calculation: Count

        • This will set up the calculation to count how many times impact.com receives purchase events that meet your criteria.

    3. Apply a fixed Tracking Window. This will cause the calculation to reset each month.

      • Select Fixed Window.

      • Select a 1 calendar month window duration.

    4. Add Filters to specify that you only want to count the purchase events with a value of $50 or more:

      • Select Add Rule.

      • For the first Condition angle-down-solid.svg [Drop-down menu], select the events.fields.revenue field.

      • Change the operator type to greater than or equal to.

      • Enter 50 as the string variable value.

      Note: JSONata expressions only accept whole numbers. When using currency, impact.com recommend using the lowest denomination used in your database configuration. If you’re not sure, contact our support team for help.

    5. Review and Save.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.