Forum Discussion
Eric
7 years agoAdvocate I
Transaction Level Running Total
I am trying to calculate running balances at a transaction level for inventory. The measures are working on a daily level but I cannot get the "Qty Before" balances to calculate correctly at a trans...
Icey
7 years agoCommunity Support
Hi Eric ,
I reproduce your question, and I think the results are correct. Can you share your PBIX to me if possible? Or a similar one. Then I can help you better.
Quantity_Reverse 2 =
CALCULATE ( SUM ( 'TMHIST'[Movement] ), ALLSELECTED (), ALL ( TMHIST[Ref No] ) )
- CALCULATE (
SUM ( 'TMHIST'[Movement] ),
ALLSELECTED (),
FILTER ( ALL ( TMHIST[Ref No] ), TMHIST[Ref No] < MAX ( TMHIST[Ref No] ) )
)Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Eric
7 years agoAdvocate I
Thanks for you help. In the end, I was able to solve the problem by coming at it from a different direction and didn't have to use this formula after all.