Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!
Hello Community -
I am in need of some help calculating a Capacity number for my providers. Below is a sample set of capcity dimensional table (it is modeled joining to a visit table which is my fact table). What I am looking to do is calculate the capacity for each provider, but when their capacity changes on a specific date, the capacity amount calculates properly.
| ProviderID | Capacity | Practice | Start Date |
| 230 | 95 | Chiro | 1/1/2023 |
| 231 | 95 | Chiro | 1/1/2023 |
| 232 | 95 | Chiro | 1/1/2023 |
| 255 | 50 | Acu | 1/1/2023 |
| 310 | 25.5 | FM | 1/1/2023 |
| 311 | 50 | Acu | 1/1/2023 |
| 353 | 28 | FM | 1/1/2023 |
| 362 | 55 | Acu | 1/1/2023 |
| 371 | 28 | FM | 1/1/2023 |
| 385 | 95 | Chiro | 1/1/2023 |
| 391 | 65 | Acu | 1/1/2023 |
| 409 | 95 | Chiro | 1/1/2023 |
| 410 | 95 | Chiro | 1/1/2023 |
| 420 | 17 | FM | 1/1/2023 |
| 420 | 10 | FM | 8/1/2023 |
So what I would like show based on the sample data above for ProviderID 420, Capacity would be 17 per month for 2023 up until 8/1/2023, once the date hits 8/1/2023 the capacity would fall to 10. So the total capacity YTD to Provider 420 would be 139 (17*7 (Jan-Jul) + 10*2 (Aug-Sep)).
How can I caculate this to be dynamic so as the capacity of providers change, the numbers in my PBI report will reflect the correct calcs?
Thank you in advance for your help!
Ryan F.
Measure1
Dynamic Capacity =
VAR CurrentDate = MAX('Date Table'[Date])
RETURN
CALCULATE(
SUM('Capacity Dimensional Table'[Capacity]),
FILTER(
'Capacity Dimensional Table',
'Capacity Dimensional Table'[ProviderID] = SELECTEDVALUE('Capacity Dimensional Table'[ProviderID]) &&
'Capacity Dimensional Table'[Start Date] <= CurrentDate
)
)
Measure2
YTD Capacity =
VAR CurrentMonth = MAX('Date Table'[Date])
RETURN
SUMX(
FILTER(
ALL('Date Table'),
'Date Table'[Date] <= CurrentMonth
),
[Dynamic Capacity]
)
Did I answer your question? If so, please mark my post as a solution!
Proud to be a Super User!
@mh2587 thanks for the help. This is very close. However, when I am looking at it by month for provider 420, once I hit August, the capacity is not 10, but it is 27 (adding up the the 2 separate capacity values). I have tried to tweak it a few different ways, but have not had luck. I would expect to see 17 from January 2023 through July, but then August forward I would expect to see 10, not 27. Any ideas on the small tweak needed here?
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
Check out the January 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 65 | |
| 64 | |
| 45 | |
| 21 | |
| 18 |
| User | Count |
|---|---|
| 115 | |
| 114 | |
| 38 | |
| 36 | |
| 26 |