Alteryx Designer Desktop Discussions

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

Dynamic sorting (descending) Last month

neromerob
10 - Fireball

Hello to everyone.

This is a workflow that I have been working on, it does the flowing things.

 

1)Get rid of duplicate and sum their values by month.

2)Arrange Month in not alphabetical order after the Sum.

3) Show information “until” the previous month (May if we are in June, until July if we are in June and so on)

4) Only show information when the record has values different from zero in every month.

 

What i´m trying to do is that the output will always gave me the report but with the previous month (in this case May) descending, considering that I will have a new “previous month” eventually so the solutions should consider that.

 

Example.

 

INPUTS_OUTPUTS.jpg

 

Thank you for all the help. 

 

 

4 REPLIES 4
DataNath
17 - Castor

How does this look @neromerob? It takes the latest month, sorts them into order and then assigns a Record ID so this can be joined back to the main flow and sort on that. Will be dynamic to new months as it parses out the header as an actual date and checks for the max:

 

DataNath_0-1656620751384.png

 

IraWatt
17 - Castor
17 - Castor

I knew there was a smarter way 😅 Nice solution @DataNath. I ended up making a macro which always sorts the last column descending:

IraWatt_0-1656620974559.png

 

DataNath
17 - Castor

@IraWatt I do love a good macro 😆

neromerob
10 - Fireball

It seem to be working, thank you very much. 

Labels