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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Show items with DueDate tomorrow excluding weekend

Hi guys,

 

I need some help creating a list of items that are due tomorrow, excluding weekends and holidays.

 

This is what I have:

A list of items

Each item has a DueDate (none of them are in weekends or holidays)

A Date table with values "1" for working day and "0" for non-working day (weekends and holidays)

A relationship between DueDate and Date from my Date table.

 

So today, the list should show all due dates that are 14-01-2020. On Friday it needs to show all items that are due on the next Monday. What's the best way to do this?

 

Thanks!!

1 ACCEPTED SOLUTION

Hi @Anonymous 

 

Try a column like that.

 

Column = 
VAR __today = TODAY() 
VAR __weekDay = WEEKDAY( __today, 2 ) 
RETURN 
IF( __weekDay = 5, __today + 3 = 'Table'[DueDate], __today + 1 = 'Table'[DueDate] )

 

 
Later you can use Filters or Slicer to filter to TRUE
 
Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

 

View solution in original post

3 REPLIES 3
Greg_Deckler
Super User
Super User

Just create a measure that subtracts the due date from TODAY(), or a calculated column if it does not need to be dynamic. You could throw an IF statement in there to check working day of TODAY. Then just filter to this measure = 1.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

Hello Greg,

 

Thanks for your input. I created a column for Table[DueDate]-TODAY(), but when I filter on "1" wouldn't it still show DueDate = Saturday (which there are none of) when today is Friday?

Doesn't this work the same as the relative date filter showing the next 1 day, excluding today?

Hi @Anonymous 

 

Try a column like that.

 

Column = 
VAR __today = TODAY() 
VAR __weekDay = WEEKDAY( __today, 2 ) 
RETURN 
IF( __weekDay = 5, __today + 3 = 'Table'[DueDate], __today + 1 = 'Table'[DueDate] )

 

 
Later you can use Filters or Slicer to filter to TRUE
 
Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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