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
Anonymous
Not applicable

Counting Working Days with criteria

Hi All,

Hope everyone is doing well.
I need some more help with adding a column instead of a measure, please 

Find the # of Days Working between Start Date and First Open Time with the criteria of:

1. Answer = Accept
2. Status <> Void

3. First Open Time after Start Date

4. Counting the Working Days, I have a dates table that counts each work day as 1, column name Is Weekday

Kryssy_3-1679209994594.png

 

1 ACCEPTED SOLUTION
Migasuke
Memorable Member
Memorable Member

Hi @Anonymous ,

I solved your issue but it consists of several steps. The results are the same as you sent me later in the printscreen.

Solution is following:

1. Create an Index column in Power Query. This will help identify which data input is earlier or later.

2. Create new column called DateDiff. This will be used later for filtering + giving results. Formula is following:

obrazek.png

3. Create new column with the Result. This DAX formula copies the logic you have. The most crucial part is within CALCULATE and MINX, where we specify which data we need to filter. Here the Index column is needed.

Migasuke_3-1679239062273.png
Let me know if you have any other question!

 





If my answer was helpful please give me a Kudos or even accept as a Solution.

Let's connect on LinkedIn!

View solution in original post

2 REPLIES 2
Migasuke
Memorable Member
Memorable Member

Hi @Anonymous ,

I solved your issue but it consists of several steps. The results are the same as you sent me later in the printscreen.

Solution is following:

1. Create an Index column in Power Query. This will help identify which data input is earlier or later.

2. Create new column called DateDiff. This will be used later for filtering + giving results. Formula is following:

obrazek.png

3. Create new column with the Result. This DAX formula copies the logic you have. The most crucial part is within CALCULATE and MINX, where we specify which data we need to filter. Here the Index column is needed.

Migasuke_3-1679239062273.png
Let me know if you have any other question!

 





If my answer was helpful please give me a Kudos or even accept as a Solution.

Let's connect on LinkedIn!

Migasuke
Memorable Member
Memorable Member

Hi @Anonymous ,

Can you please give example of a result?
Do you want to calculate days only for fulfilled criteria? And what do you want to see if the criteria is not fulfilled?

 



If my answer was helpful please give me a Kudos or even accept as a Solution.

Let's connect on LinkedIn!

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.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.