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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
XeperRx
Frequent Visitor

Ignore certain time periods during duration calculations

Hello, 

 

I'm calculating total build time. Here is the DAX calculation that I'm using - 

 

Build Time = DATEDIFF('Job Management Historical'[Build Start], ('Job Management Historical'[Potting Staged]), MINUTE) + (DATEDIFF('Job Management Historical'[Build Resume Time], ('Job Management Historical'[Build Complete]), MINUTE))
 
I need to ignore certain time periods in this calculation - 
 
M-F : 12:00 PM - 12:30 PM 
M-Th :  4:30 PM - 8:00 AM
Weekends : F 4:00 PM - M 8:00 AM 
 
Thank you in advance for your help! 
1 ACCEPTED SOLUTION
harshnathani
Community Champion
Community Champion

Hi @XeperRx ,

 

 

Please check if these help.

 

https://exceleratorbi.com.au/calculating-business-hours-using-dax/

https://exceleratorbi.com.au/calculating-elapses-business-hours-using-dax-part-2/

 


Regards,

Harsh Nathani


Appreciate with a Kudos!! (Click the Thumbs Up Button)

Did I answer your question? Mark my post as a solution!

View solution in original post

2 REPLIES 2
harshnathani
Community Champion
Community Champion

Hi @XeperRx ,

 

 

Please check if these help.

 

https://exceleratorbi.com.au/calculating-business-hours-using-dax/

https://exceleratorbi.com.au/calculating-elapses-business-hours-using-dax-part-2/

 


Regards,

Harsh Nathani


Appreciate with a Kudos!! (Click the Thumbs Up Button)

Did I answer your question? Mark my post as a solution!

@harshnathani ,

 

Thank you!! This is exactly what I was looking for!

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.