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
julsh41
Helper II
Helper II

Writing a Measure with a Cap

I am trying to write a measure for project cost, but I would like it with a max hour cap per month.  

 

Worker A and B each salaried employees and over 2080 possible hours in a year have an effective cost $100/hr, August has 176 possible billable hours.

 

Worker A works 75 hours = 75 X 100 = Project cost of $7500

Worker B works 204 hours = 176 X 100 = Project cost of $17,600

 

While the revenue for Worker B would be based on 204, I would like the cap to be on the monthly possible hours as that person's cost for a month would not increase based on how many hours they billed since they are salaried.  

 

Can anyone help with this?  Happy to clarify if this doesn't make sense.  

 

 

3 REPLIES 3
pbeye
Resolver II
Resolver II

Would something like this work?

 

capped = IF(SUM(hoursworked) > 176, 176 * 100, SUM(hoursworked))

The complexity is I have 30 workers with their different cost rates and each month has varying possible billable hours depending on how many weekdays in the month so I can't hard code each workers cost amount or each months possible hours.    

That makes sense. I'm assuming you have both of those fields already in the daaset? If so, you should be able to just switch them out in the formula above.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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.

Top Solution Authors
Top Kudoed Authors