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 August 31st. Request your voucher.

Reply
aziz_123
New Member

how to calculate working days without weekend or holiday

I have a database contains ID - createdon - [Branch Officer Start Work Date]- [Branch Manager Start Work Date]-[Approval Date]

FypADKjV (1).png

 

I want to calculate working days by sql without weekend or holiday for Branch officer and Branch Manager for each request

the fourmla is :

branch officer= created on - branch officer start work date

Branch Manager= Branch Manager start work date - approval date



if branch officer work more then 4 days it will be delayed and count (id) if branch officer Manager more then 6 days it will be as delayed count (id)

out put will be like

7AKIftIe.png

 

Thank you..

 
1 ACCEPTED SOLUTION

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
Do not include sensitive information. Do not include anything that is unrelated to the issue or question.
Please show the expected outcome based on the sample data you provided.

Need help uploading data? https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Want faster answers? https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

View solution in original post

6 REPLIES 6
v-priyankata
Community Support
Community Support

Hi @aziz_123 

Thank you for using Microsoft Community Forum.
As we haven't heard from you, we hope your issue has been resolved. Please feel free to contact us if you have any further questions, and raise a new ticket if you have any other issues.
Thank you.

v-priyankata
Community Support
Community Support

Hi @aziz_123 

Thank you for using Microsoft Community Forum.

Can you Please share some sample data so that we can analyze the issue and suggest possible solutions.
Thanks.

v-priyankata
Community Support
Community Support

Hi @aziz_123 

Thank you for using Microsoft Community Forum. 

Please share some sample data so that we can analyze the issue and suggest possible solutions. thanks @lbendlin for your inputs.
Thanks.

lbendlin
Super User
Super User

Please read up on the NETWORKDAYS function. You can supply your weekend rules and the holidays to it and it will return the net workdays.

 

If you want to do that manually, use INTERSECT and EXCEPT.

Can you explain more please..

It's not a manual data, Actually it's huge data.

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
Do not include sensitive information. Do not include anything that is unrelated to the issue or question.
Please show the expected outcome based on the sample data you provided.

Need help uploading data? https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Want faster answers? https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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