Alteryx Designer Desktop Discussions

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

how to sort date from oldest to newest for particular number and create blank rows

prthmesh111
8 - Asteroid

below is the input file which contains number, date and type

NumberTypeDate
1234               received9/13/2023
1234received9/13/2023
1234delivered9/13/2023
2356received10/22/2023
2356received5/22/2023
2356received10/22/2023
2356received5/22/2023
2356delivered5/22/2023
2356delivered10/22/2023

 

Output should be like below

 

NumberTypeDate
1234               received9/13/2023
1234received9/13/2023
1234               delivered9/13/2023
   
2356received5/22/2023
2356received5/22/2023
2356delivered5/22/2023
   
2356received10/22/2023
2356received10/22/2023
2356delivered10/22/2023
   

the sorting must be based on date and matching number and it should generate empty rows after every delivered type

 

 

5 REPLIES 5
wwatson
12 - Quasar

You should start by making sure the date column is defined as a date rather than a string. From first glance the Date column looks like  a string. You can convert it to a date using the DateTime Parse tool.

 

 

wwatson_0-1594643711080.png

 

Once parsed to a date type the normal sort tool should sort it correctly.

Thableaus
17 - Castor
17 - Castor

Hi @prthmesh111 

 

Here's one alternative. WF attached.

 

Thableaus_0-1594646184028.png

 

 

Cheers,

wwatson
12 - Quasar

Full solution enclosed:

wwatson_0-1594645965011.png

 

prthmesh111
8 - Asteroid

thanks for the solution. it was same as required . could you please help me in one more question below is the link

 

https://community.alteryx.com/t5/Alteryx-Designer/how-to-compare-each-row-of-received-number-with-de...

prthmesh111
8 - Asteroid

thanks for the reply . you to provided a right soution. but the perfect one which work on my dataset as expected is of wwatson

Labels