Alteryx Designer Desktop Discussions

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

date sorting

ntudev
8 - Asteroid

Hello Everyone,

 

I am working on a monthly report that compares 3 dates from each months. I have a report that runs from 2022-11-30 to 2022-12-31.

 

Beginning of last month (2022-11-30)

middle of this month (2022-12-15"

and end of this month (2022-12-31)

 

How do I get Alteryx to automatically figure out beginning, middle and end of months and separate them into 3 groups so i can compare them? I have been using a 3 filters for each dates, but its not sustainable to just keep changing them every month.

2 REPLIES 2
JamesCharnley
13 - Pulsar

Hi @ntudev 

 

Not sure I can give you an exact workflow without more details but I'm guessing that date functions will help you out massively here. You can find more about them here: https://help.alteryx.com/20223/designer/datetime-functions

 

In particular I'm thinking of functions like DateTimeLastOfMonth(), or DateTimeFirstOfMonth() in conjunction with DateTimeAdd to take a day off to dynamically find the first or last day of the previous month. You could probably use it to find the middle too.

 

JamesCharnley_0-1673020205339.png

 

 

Does that help?

gautiergodard
13 - Pulsar

Hey @ntudev 

Here is one way to do this! 

See attached workflow. Hope this helps! Please accept as solution is this solved your issue.

Labels