Log aggregated numbers on a schedule
Recipe ToolsMarketing
What it does
When a scheduled trigger fires every 5 minutes, this automation creates a variable to track a total count. It loops through a list, updates the sum with each item, and logs the result to the job report.
Who it's for
Data and analytics teams who need to aggregate numbers at regular intervals without manual work.
Apps used
How teams use this
Aggregate numbers without manual work
Sum numbers from a data source every 5 minutes and log the result to a report. The team sees the aggregated count without opening a spreadsheet or running calculations by hand.
Monitor KPI totals in real time
Run the sum calculation at shorter intervals to track a KPI that changes frequently. Only the schedule timing changes, and the logic stays the same.
Filter items before summing
Add a condition to the loop so only items that meet a criteria are included in the total. This requires a filter step before the sum is calculated.
How it works
- Start on a 5-minute schedule. Clock triggers this automation every 5 minutes so the sum calculation runs at regular intervals without someone having to start it.
- Create a total count variable. Set up a variable called TotalCount to hold the running sum as the automation processes each item in the list.
- Loop through each item. Repeat the next steps for every item in the list so each number is added to the total count variable.
- Update the sum. Add each item to the TotalCount variable so the running total grows with every iteration through the list.
- Log the result. Write the final sum to the job report so the aggregated count is visible and auditable after the automation completes.