Forum Discussion
Pivot on Multiple Dimensions and Values
- 6 years ago
Anonymous first you don't need to sum these in power query, you can load raw data and just sum in your visual. If you still want to do grouping in power query, there is group by option in the menu, pick , date to group by and use two columns to sum in the same dialog box.
I would ❤ Kudos if my solution helped. 👉 If you can spend time posting the question, you can also make efforts to give Kudos whoever helped to solve your problem. It is a token of appreciation!
⚡Visit us at https://perytus.com, your one-stop shop for Power BI related projects/training/consultancy.⚡
In Power Query:
- Select the Date and Product ID columns
- On the home ribbon, select Group By
- In the bottom section add the Sales value, call it Sales, Sum operation, and Sales column
- Add an aggregation, then do Profit, Sum Operation, Profit column.
It would look like this, but with your columns.
It is good you are doing this. Having data at the right granularity is key to a good data model, and if you don't need the duplications of dates and product IDs, Power Query is the best way to do this.