Forum Discussion
Casperserven1
3 years agoHelper I
Accumulating using previous
I am trying to do tthe following and struggling - I am sure this is easy but just can't see it. New Hires Retirees Total Workforce 3 5 20 6 3 23 8 1 30 9 8 31 4 6 ...
- 3 years ago
Now I got it. Please try
Total Workforce =
VAR StartingWF = 22
VAR TableBefore =
FILTER ( 'Table', 'Table'[Date] < EARLIER ( 'Table'[Date] ) )
VAR Change =
SUMX ( TableBefore, 'Table'[New Hires] - 'Table'[Retirees] )
RETURN
StartingWF + Change
Casperserven1
3 years agoHelper I
yeah sure
tamerj1
3 years agoCommunity Champion
Now I got it. Please try
Total Workforce =
VAR StartingWF = 22
VAR TableBefore =
FILTER ( 'Table', 'Table'[Date] < EARLIER ( 'Table'[Date] ) )
VAR Change =
SUMX ( TableBefore, 'Table'[New Hires] - 'Table'[Retirees] )
RETURN
StartingWF + Change