Example: Today is 05/29, the function should return the next working day will be 06/01.
Does anyone have any idea how this can be done in dax?
thank you
I don't factor in Holidays, but for eliminating the weekends:
if(WEEKDAY([date],2)<5,[date] + 1,[date] + (8 - WEEKDAY([date],2)))
Hi @Anonymous
Probably best to have a calendar table that has a column indicating whether a day is a business day. Then you could obtain the next business date with something like:
CALCULATE (
MIN ( CalendarTable[Date] ),
FILTER (
ALL ( CalendarTable[Date], CalendarTable[isBusiness] ),
CalendarTable[Date] > TODAY ()
&& CalendarTable[isBusiness] = "Yes"
)
)
Please mark the question solved when done and consider giving kudos if posts are helpful.
Contact me privately for support with any larger-scale BI needs, tutoring, etc.
Cheers
Come together to explore latest innovations in code and application development—and gain insights from experts from around the world.
Put your data visualization and design skills to the test! This exciting challenge is happening now through May 31st!
User | Count |
---|---|
127 | |
65 | |
35 | |
27 | |
23 |
User | Count |
---|---|
140 | |
76 | |
40 | |
38 | |
21 |