We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

Dynamic last 3 days

Divyajyothi7
8 - Asteroid

Hi

I'm looking pick last 3 days plus future dates

for example: 

today's date 16-05-2023, it should pick 15,14,13 and future dates also including today's date

tomorrow's date is 17-05-2023, it should 16,15,14 and future dates also including today's date

 

date
25-05-2017
11-01-2018
01-05-2019
12-05-2023
13-05-2023
14-05-2023
15-05-2023
16-05-2023
17-05-2023
19-05-2025
20-01-2024
21-05-2025
03-07-2028
05-05-2034

 

Expected output:

 

13-05-2023
14-05-2023
15-05-2023
16-05-2023
17-05-2023
19-05-2025
20-01-2024
21-05-2025
03-07-2028
05-05-2034
4 REPLIES 4
ShankerV
17 - Castor

Hi @Divyajyothi7 

 

Step 1: Convert the date to ISO format yyyy-mm-dd

Datetime tool to be used

 

Step 2: Use filter tool

Use datetimeadd() function to filter Today-3 days.

 

 

Many thanks

Shanker V

binuacs
21 - Polaris

@Divyajyothi7 One way of doing this

binuacs_0-1684226249254.png

 

 

Divyajyothi7
8 - Asteroid

my data is in alteryx format only "yyyy-mm-dd"

I have used the same formula 

please let me know why 13th date is not picking

 

Divyajyothi7_0-1684226913138.png

 

binuacs
21 - Polaris

@Divyajyothi7 include the toDate() function

toDate([date]) >= toDate(DateTimeAdd(DateTimeToday() ,-3,'day'))

 

Labels
Top Solution Authors