Alteryx Designer Desktop Discussions

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

Alteryx Designer - Dynamic Filter and Date formula

STAR1BANU
8 - Asteroid

I have attached the sample data I need a solution, every month if I  run the Alteryx Workflow if the current month is March 2021 the workflow automatically filter the Mar BS details from data B and Merge with Mar PL in Data A likewise if I run the workflow in the month of Apr 2021 it will pick the data in Apr BS details from data B and merge with Apr PL and delivered the output  

 

Please suggest how to apply the dynamic filter and date formula at the earliest

4 REPLIES 4
pedrodrfaria
13 - Pulsar

Hi @STAR1BANU 

 

You just need to set up this logic with a filter:

 

left([Month],3) = DateTimeFormat(DateTimeToday(),"%b") 

 

Here we will match today's month with the datasets you have using the short version of the name of the month (thus using the "%b"). 

 

I attached a WF to show you.

 

I was not 100% on how we needed to prep the data before joining. Let us know if you need any additional help.

 

Pedro.

 

 

STAR1BANU
8 - Asteroid

if I run the workflow for next month it automatically picks APR 2021??

Qiu
20 - Arcturus
20 - Arcturus

@STAR1BANU 
I believe the anwser is correct.

the DateTimeToday() function in left([Month],3) = DateTimeFormat(DateTimeToday(),"%b") returns the the Date in yyyy-mm-dd format of the workflow being run.

So if you run it in April, it will return a date of April. Then the %b is used to format yyyy-mm-dd into mm.

STAR1BANU
8 - Asteroid

awesome response let me try and get back to you 

Labels