Forum Discussion
jeronimo2334
Helper III
7 years agoCalculate Balance based on Date
Hi all, So I have 3 tables, one with customers, one with customers' charges and one with customers' payments. I am trying to figure out a good way to get a balance for each customer. The user wan...
- 7 years ago
jeronimo2334 hope attached will get you going
MisterFry
Resolver III
7 years agoYou could create a disconnected date slicer that allows the user to select a date, detect that date via SELECTEDVALUE(), and use Balance = CALCULATE(SUM(CREDITS), date <= SELECTEDVALUE([DisconectedDateField])) - CALCULATE(SUM(DEBITS), date <= SELECTEDVALUE([DisconectedDateField]))
You could generate the list of dates by either doing a SUMMARIZE() on a concatenation of your other table's date fields, or you could autogenerate them in power query using List.Generate()