In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Finding Specific Date for Specific Weekday

Nsantana
7 - Meteor

How can I find the date for a previous day of the week based on a date in the following week?

 

Example:

I need the previous Thursday

8/18/21 would bring in 8/12/21

8/17/21 would bring in 8/12/21

8/20/21 would bring in 8/12/21

I would like to pull in the previous Thursday, despite what day of the week the date for lands on.

 

This makes it so that the counting days formula doesn't work in this scenario. 

2 REPLIES 2
dataguyW
11 - Bolide

Many ways to get there.  Here is one.  DateTimeAdd(DateTimeTrim([INPUT_DATE],'day'),-1* (ToNumber(DateTimeFormat([INPUT_DATE],"%w"))+3),'days')

Nsantana
7 - Meteor

Thank you

Labels
Top Solution Authors