Forum Discussion
Balance for Calculation for each entry in the Balance
- Anonymous2 years ago
Hi Rafael_Batista_ ,
I made simple samples and you can check the results below:
Balance = var _Expense = MAX('Table'[Expense]) RETURN IF(_Expense=BLANK(),MAX('Table'[Revenue]),-MAX('Table'[Expense])) Total = var _t = ADDCOLUMNS('Table',"TOTAL",SUMX(FILTER(ALL('Table'),[ID]<=EARLIER([ID])),[Balance])) RETURN MAXX(_t,[TOTAL])An attachment for your reference. Hope it helps!
Best regards,
Community Support Team_ Scott ChangIf this post helps then please consider Accept it as the solution to help the other members find it more quickly.
Hi Rafael_Batista_ ,
I made simple samples and you can check the results below:
Balance = var _Expense = MAX('Table'[Expense])
RETURN IF(_Expense=BLANK(),MAX('Table'[Revenue]),-MAX('Table'[Expense]))
Total = var _t = ADDCOLUMNS('Table',"TOTAL",SUMX(FILTER(ALL('Table'),[ID]<=EARLIER([ID])),[Balance]))
RETURN MAXX(_t,[TOTAL])
An attachment for your reference. Hope it helps!
Best regards,
Community Support Team_ Scott Chang
If this post helps then please consider Accept it as the solution to help the other members find it more quickly.
- Rafael_Batista_2 years agoRegular Visitor
Thaks for your answer, but for me isn't work because [ID]
I haven't this Data- Anonymous2 years agoNot applicable
Hi Rafael_Batista_ ,
This ID column is not required, you can replace it with a date column.
Hope it helps!
Best regards,
Community Support Team_ Scott ChangIf this post helps then please consider Accept it as the solution to help the other members find it more quickly.