Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Selecting Holiday Dates in a sheet and changing them to the next working day

Gandalf_NotGrey
8 - Asteroid

Hello,

I am building a workflow where I am facing this challenge.

I have attached two files - 'Primary Data Sheet' and 'Holiday Reference Sheet'

So, my main data is in the 'Primary Data Sheet'. There is a column with Dates in it. My objective is, I have to use another source, here it is the 'Holiday Reference Sheet' and check is any of these dates are in my 'Primary Data Sheet'. If there is a date which is a holiday and is there in the 'Primary Data Sheet', then I have to edit that to the next working day. 

Possibilities -

In case of two continuous holidays, I need to add two days using datetimeadd to the Main Date field. Similarly in case of three or four continuous holidays. 

I also need to skip the weekends and go to the next working day. So, if a Holidays falls on Friday, then next working day will be Monday (assuming Monday is also not a holiday).

 

Hope I am able to make myself clear. In brief - I need to see in my 'Primary Data Sheet', which dates are holidays and then skips those dates plus any weekends if they are there and change the 'Mian Date' field to the next working day.

Any suggestion will be much appreciated.

 

Thank You so much. 

3 REPLIES 3
binuacs
20 - Arcturus

@Gandalf_NotGrey One way of doing this

binuacs_0-1681731738836.png

 

Christina_H
14 - Magnetar

Here's my solution.  I added 26 December to the list of holidays to show that it works for consecutive holidays (both 25 and 26 December will be replaced with 27 December)

Christina_H_0-1681734326143.png

 

Gandalf_NotGrey
8 - Asteroid

Thanks You so much @binuacs and @Christina_H for your responses. Much Appreciated.

I used your solution @Christina_H ,had to make few changes to incorporate some additional logic. I must say, I really liked your logic, quite ingenious.

Labels