Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
VitorXavierCell
Regular Visitor

Stock Variation in a time line

Hello,

 

I have a table that controls my stock, what goes in and what goes out, day by day. I need to create a graphic that shows me this variation in a waterfall chart, but I am not getting the right result. How can I do the formula to shows the accumulated variation on a period of time?

 

In my table I have the columns: Product, Data, Stock in, Stock Out.

 

Best Regards.

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@VitorXavierCell , You might need a measure like

 

CALCULATE(SUM(Table[Stock in]),filter(date,date[date] <=maxx(date,date[date]))) - CALCULATE(SUM(Table[Stok Out]),filter(date,date[date] <=maxx(date,date[date])))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@VitorXavierCell , You might need a measure like

 

CALCULATE(SUM(Table[Stock in]),filter(date,date[date] <=maxx(date,date[date]))) - CALCULATE(SUM(Table[Stok Out]),filter(date,date[date] <=maxx(date,date[date])))

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Hello @amitchandak , thank you for answer my question!

 

I tried to use your sugestion, but it results the same as I did before, because the measure don't accumulate the balance between it on the time line.
I attached a image that shows the month, The quantity In, quantity out and the measure "Stock Variation".

 

Stock Variation.PNG

 

Thanks a lot

@amitchandak Actually I was using the filter with a different table, that's why I not got it, but now I change the source of the filter and it worked.

 

Thanks a lot for the help!

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.