Forum Discussion
Stock Tracking Resetting
- 7 months ago
Hi yz___
Thank you for your question on the Microsoft Fabric Community Forum.
While I’m not fully aware of the exact structure of your dataset, I’ve created a sample .pbix file to demonstrate one possible approach for modeling stock depletion over time by part, ensuring the rolling balance depletes correctly without resetting due to date hierarchies or aggregation issues.I’ve attached a screenshot and the .pbix file illustrating this logic. Please review them to confirm whether this approach aligns with your requirements.
I hope this information is helpful. . If you have any further questions, please let us know. we can assist you further.
Regards,
Microsoft Fabric Community Support Team.
Hii yz___
The line resets because the running total is calculated over all dates, so after the last work-order date Power BI keeps evaluating extra dates and the balance appears to bounce back. The correct approach is to calculate Starting Stock – Cumulative Demand per Part up to the current date, and then return BLANK() for dates after the last demand date of that part. This keeps the running balance continuous per part and stops the line exactly at the final work-order date, preventing any reset behavior.