Free Trial

Alteryx Designer Desktop Discussions

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

Group by function

aparna0208
8 - Asteroid

Hi,

 

I need help with group by function and not sure if I'm doing it right. I have few columns and one being the ID column. In some cases, the IDs are repetitive. I need to group them based on the ID and be able to see the output including all columns. Basically the output should have one set for each ID as indicated below under expected output section. Thanks in advance!

 

For example

 

ID      Account Name      Edited by     owner

1        ABC                       user 1          john

1        abc                         user 2          harry

3        XYZ                        user 3          paul

3        Xyz                         user 4          linda

 

Expected output

 

Firm CRD  Account OwnerEdited ByAccount Name
1johnuser 1ABC
 harryuser 2abc
3paul user 3XYZ
 lindauser 4Xyz
3 REPLIES 3
fmvizcaino
17 - Castor
17 - Castor

Hi @aparna0208 ,

 

I'm attaching a solution where I'm using the tile tool to count the number of equal IDs and then a formula tool to remove the ID data from equal ID rows.

 

Best,

Fernando Vizcaino

grossal
15 - Aurora
15 - Aurora

Hi @aparna0208,

 

if the data is already sorted by ID, you could use a Multi-Row-Formula to achieve this:

 

grossal_1-1586467482289.png

 

 

This will check if IDs of two continues rows are the same, if so, it writes Null(), else it write the current ID.

 

Output:

grossal_2-1586467514484.png

 

 

Workflow attached. Let me know what you think.

 

 

Best

Alex

aparna0208
8 - Asteroid

Awesome!! Both solutions worked exactly the way I wanted:) Thank you so much for your quick response:) @grossal @fmvizcaino  

Labels
Top Solution Authors