Alteryx Designer Desktop Discussions

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

How to filter month to date data

SJDC
6 - Meteoroid

Hello Team, Can someone help me on how can I filter month to date data in the below sample input file:

 

SJDC_0-1629858137667.png

 

Thank you.

8 REPLIES 8
ncrlelia
11 - Bolide

Hi @SJDC,

 

There are a few ways to do this depending on your needs.

Essentially, the idea is to parse your date into a format that Alteryx recognises as a date. Then use DateTimeFormat to get the Month value, and subsequently filter the month value

I've included 2 variations of month value, that is the Abbreviated Month name and Month number. If you are filtering by a range then the month number will be better. You can refer to https://help.alteryx.com/20213/designer/datetime-functions for specifiers for other formats of month value.

 

Please see attached my suggested solution.

Hope it helps.

 

Thank you.

 

Best Regards,

Lelia

binay2448
11 - Bolide

Hope this can help ....

SJDC
6 - Meteoroid

Appreciate your help! this works! 🙂

atcodedog05
22 - Nova
22 - Nova

Hi @SJDC 

 

If the solution author's response helps please don't forget to mark it as a solution.

Cheers and have a nice day!

SJDC
6 - Meteoroid

Actually I just new that it captures previous year

 

SJDC_0-1629982083568.png

can you help as well with the current year?

atcodedog05
22 - Nova
22 - Nova

Hi @SJDC 

 

Here is the formula for it

if [DateTime_Out]>=DateTimeFirstOfMonth()
then 1 else 0 endif

 

Workflow:

atcodedog05_0-1629982693403.png

 

Hope this helps : )

SJDC
6 - Meteoroid

Thank you all for your help! 🙂

atcodedog05
22 - Nova
22 - Nova

Happy to help : ) @SJDC 

Cheers and have a nice day!

Labels