Hi!
can someone please help me figure out how to get the data from the current data format to the desired data format? i tried cross tab but i must have done something wrong...
Current Data | ||||||
Date | Name | Type | Product 1 | Product 2 | Product 3 | Product 4 |
8/11/2021 | A | 1 | Product 1 | Product 4 | ||
8/11/2021 | B | 2 | Product 1 | Product 2 | ||
8/11/2021 | A | 3 | Product 2 | |||
8/11/2021 | B | 4 | Product 2 | Product 3 | ||
8/11/2021 | A | 5 | Product 1 | Product 2 | ||
8/11/2021 | B | 6 | Product 1 | |||
8/12/2021 | C | 7 | Product 4 | |||
8/13/2021 | C | 8 | Product 3 |
Desired Data | |||
Date | Name | Type | Product |
8/11/2021 | A | 1 | Product 1 |
8/11/2021 | A | 1 | Product 4 |
8/11/2021 | B | 2 | Product 1 |
8/11/2021 | B | 2 | Product 2 |
8/11/2021 | A | 3 | Product 2 |
8/11/2021 | B | 4 | Product 2 |
8/11/2021 | B | 4 | Product 3 |
8/11/2021 | A | 5 | Product 1 |
8/11/2021 | A | 5 | Product 2 |
8/11/2021 | B | 6 | Product 1 |
8/12/2021 | C | 7 | Product 4 |
8/13/2021 | C | 8 | Product 3 |
Hi @nora_m
Here is how you can do it.
Workflow:
1. Using transpose with key columns as Date, Name and Type converting product columns to rows.
2. Using select to rename the column as product.
3. Using filter tool to keep only non null value in product.
Hope this helps : )