Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Discussions

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

how to sort out a column contains a specific items with another column

parida
5 - Atom

Hi mentor, 

 

I have a dataset that includes two columns of data. one is invoice_id, another one is product type. For one same invoice_id, it may include more than one product types. now, my task is to find out the product types that include a specific product called "AU pre-Registration" under the same invoice_id. The included product types with "AU pre-Registration" are not the same for different invoice_id. 

 

here is the dataset looks like: 

parida_0-1648009465959.png

 

So which tool I can use to effectively sort out all results for big datasets? Thank you. 

8 REPLIES 8
JarekSkudrzyk
11 - Bolide

@parida 

hi, you can use this workflow - it will give you a summary of the ids of entries

 

if you would like to sort the data by these categories - you can use the second stream from the attached workflow

JarekSkudrzyk_0-1648017005079.png

 

JarekSkudrzyk
11 - Bolide

@parida 

let me know if that is what you are looking for. If not I ll try to help.

parida
5 - Atom

Thanks for your reply, unfortunately, it doesn't work on my side. I attached my workflow and dataset. 

 

And I think it can't answer my question either. I want to know, what other product types are in the same invoice_id with product type named "AU pre-registration". I want to show those other product types in a list if possible. 

binuacs
21 - Polaris

@parida 

binuacs_0-1648020680042.png

 

parida
5 - Atom

Thank you, but if you check the list, it also includes the invoice_id that only has one product type called "AU Pre-reg", but what I want is, the list of product types that were purchased along with  "AU Pre-reg" in the same invoice_id.  

 

I don't need to have the invoice_id only have product_type  "AU Pre-reg". 

parida
5 - Atom

to make it in a more clear way: I only want to have the list that includes >=2 product types in one same invoice_id, and one of the product types should be  "AU Pre-reg". 

 

FYI: some invoice_id includes >=2 products types, but it may not include  "AU Pre-reg", those are not what I want. 

sparksun
11 - Bolide

My solution,hope it works for you

sparksun_0-1648028474107.png

 

 

binuacs
21 - Polaris

@parida 

binuacs_0-1648029325917.png

 

Labels