Community Spring Cleaning week is here! Join your fellow Maveryx in digging through your old posts and marking comments on them as solved. Learn more here!

Alteryx Designer Desktop Discussions

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

Next Sunday Date Formatting

magsbiel
7 - Meteor

Hi,

 

How do I create a column that will shows future Sunday date.

Let's say today is 3/2/2021 and this will be my "Current Date" column, now I want to add another column " Next Sunday"which will be dated as 3/7/2021?

 

Thank you!

 

 

 

 

 

3 REPLIES 3
Emil_Kos
17 - Castor
17 - Castor

Hi @magsbiel,

 

I have created a solution for you.


What I have done is I have created a row for every 7 next days and I am showing. After that, I identify which ones are the Sundays and I filtered out all Sundays.

 

Emil_Kos_0-1614716713622.png

If this was helpful please mark my post as a solution!

AngelosPachis
16 - Nebula

Hi @magsbiel ,

 

You can do that via using a formula tool. The formula tool can be configured in a way that it checks what day of the week is today, and based on that it will add the correct number of dates till the next Sunday.

 

The function that allows you to find the days to next Sunday is the switch function, so if today is a Monday you should add 6 days till next Sunday, if today is Wednesday you should add 4 days and so on.

 

To find the actual date, you just need to use a Datetimeadd function to add the additional days to today's date.

 

AngelosPachis_0-1614716800577.png

 

Hope that helps, let me know if that worked for you.

 

Regards,

 

Angelos

messi007
15 - Aurora
15 - Aurora

@magsbiel,

 

Please see below:

 

messi007_0-1614717303490.png

Attached the workflow,

Regards,

Labels