I have tables with monthly data, and I need to calculate row-level summations. I also need a column-level summation for all columns.
My columns are:
Project ID | Name | Budget Year | Total Amount | Sum Total | Jan | Feb | ... | Dec
'Total Amount' is a calculated column, but this doesn't provide me with the column-level total, so I have a 'Sum Total' currency column that I populate using a flow that gets triggered every time something gets created or modified.
To ensure I don't run into an infinite loop, I have the below in the Trigger Condition:
@not(equals(triggerBody()?['Total_x0020_Amount'], triggerBody()?['SumTotal']))
Alternatively, I also tried:
@not(equals(triggerOutputs()?['body/Total_x0020_Amount'], triggerOutputs()?['body/SumTotal']))
Neither of these work and my flow keeps firing. Could someone point me in the right direction?
I managed to fix this by having a Condition block that performs the update only when any of the specific monthly columns get updated. The flow still gets triggered on every edit, but this condition throttles the flow considerably and has been very reliable so far.