Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Group by the multiple values in one column

Hello. I have a some columns in my file that correspond to customer's orders: order date, payment date, Number of order, product typology, etc.  The behavior of the file is: when some customer order more than 1 item, it creates two lines for the same order, for example:

Num_Order       Orderdate             SKU              typology         

1234                   10/09/2020           123456        23

1234                   10/09/2020           765432         22

 

I want to do a group by by Num_Order so i can identify how many orders are mono orders (1 item) and how many are multi orders (more than 1 item). The problem is that I need to add to this group by the item's typology and customers can order itens from the same typology and different as well. 

 

I need this information for doing an analysis of how many customers did a multi order for all itens typologies except "23", by excluing the order lines that have typology "23" and maintain the rest. 

3 Replies