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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Sum Over Interval in Two Columns

Hi there! 

 

I have a database that show me some ongoing and scheduled processes, how many goods are being used, start month and end month of every process. Most of them take about 3 months to complete, and I need a measure to sum how many materials are being used per specific month.

 

I tried using CALCULATE ( SUM (), FILTER), I can make it sum everything in the start and end months, but I wasn't able to make PowerBI sum everything in between. So if it starts in Jan and ends in March, it gotta sum it in Feb as well. 

 

E.g.:

JanFebMarAprMayJune
100102108100111130

 

Does anyone know any content that can help me solve this?

 

Thanks!

3 REPLIES 3
Anonymous
Not applicable

Hi @Anonymous 

So, what does the result you want to achieve look like ? Could you describe the result you want through formulas or specific data , maybe this will help us solve the problem better.

 

Best Regards,
Community Support Team _ Ailsa Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi @Anonymous ,

 

This is the real database below. The third column is the quantitites I need to sum. The #5 is the starting month and #6 is the end month. 

gustavor0_1-1649158434786.png

 

I have this table that shows me, per month, the sum of everything coming back and everything leaving my warehouse. Now I would like to add a third column with Total Out of Stock. So, if a material is taken in May-2022 and is returned in July-2022, it should be summed in May, June and July (where I marked the X below).

And I have no clue of how to create this measure. The interval is defined by those 2 columns above. 

gustavor0_2-1649158564244.png

Thanks!

tamerj1
Super User
Super User

@Anonymous 

Not sure if I fully understand but did you with simple SUM. As I did not understand the use of FILTER

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.