For more details on this weekly challenge visit Preppin Data
Link to Challenge - https://preppindata.blogspot.com/2021/08/2021-week-36-excelling-in-prep.html
The weekly sales of Bike Components from Preppin's bike store Allchains is what we are analysing. The returns are where the product has been deemed faulty before it's sold.
- Input data
- Remove the 'Return to Manufacturer' records
- Create a total for each Store of all the items sold
- Aggregate the data to Store sales by Item
- Output the data
- Input the data
- Filtered out the items where the status did not equal "Return to manufacturer"
- Changed the "Number of Items" field from a string to an integer for use in future steps
- Used the Cross Tab tool to separate the "Items" column into separate columns per distinct item
- I used the Tranpose column to turn the separate item columns back into one column containing the number of items sold
- Used the summarize function to sum the number of items sold per store
- Joined the Items sold per store to the output of Step 4
- Results