Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
I created a working days table that identifies each day of the year 2021 as a working day or not using @amitchandak's example here from 2020
Here's what my date table now looks like:
My objective is to create a measure that calculates the number of working days elapsed from one date, to the current date. Here's an example below of what I'm trying to achieve
Latest Submission Date is my data, that I need to subtract from the current date, but only counting working days
Latest Submission Date | New measure here: working days elapsed |
1/20/2021 | ?? |
1/21/2021 | ?? |
1/22/2021 | ?? |
1/23/2021 | ?? |
1/19/2021 | ?? |
1/1/2021 | ?? |
Solved! Go to Solution.
Hi @Anonymous ,
Based on your description, you can create a measure as follows.
working days elapsed =
VAR x1 =
FILTER (
ALL ( 'calendar' ),
[Date] <= TODAY ()
&& [Date] >= SELECTEDVALUE ( 'Submit'[Latest Submission Date ] )
&& WEEKDAY ( [Date], 2 ) < 6
)
RETURN
COUNTROWS ( x1 )
Today is 2/22/2021.
Result:
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
Based on your description, you can create a measure as follows.
working days elapsed =
VAR x1 =
FILTER (
ALL ( 'calendar' ),
[Date] <= TODAY ()
&& [Date] >= SELECTEDVALUE ( 'Submit'[Latest Submission Date ] )
&& WEEKDAY ( [Date], 2 ) < 6
)
RETURN
COUNTROWS ( x1 )
Today is 2/22/2021.
Result:
Hope that's what you were looking for.
Best Regards,
Yuna
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , Try a new measure
Work Day = COUNTROWS(FILTER(ADDCOLUMNS(CALENDAR(max(Table[Latest Submission Date]),TODAY()),"WorkDay", if(WEEKDAY([Date],2) <6,1,0)),[WorkDay] =1))
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
143 | |
85 | |
66 | |
51 | |
45 |
User | Count |
---|---|
217 | |
89 | |
82 | |
66 | |
57 |