The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event! Join us in Stockholm, Sweden from September 24-27, 2024.
2-for-1 sale on June 20 only!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
Hi,
Below I have added a screenshot of the dataset I have. I have two requirements that I need to implement on top of this dataset. I do not believe this is doable in DAX so I am requesting this be complete using Power Query.
Requirement 1:
For each Division and Category, like a Group By, I require a new row creating with the text of 'SSGP' added as the Grouping_Level value, and the value field containing the sum (Sales - Costs). For example,
Division Grouping_Level Category Value
South East SSGP DEValue (whatever the (Grouping_Level.Sales - Grouping_Level.Costs) calculation returns)
South East SSGP DETarget (whatever the (Grouping_Level.Sales - Grouping_Level.Costs) calculation returns)
South East SSGP MTDValue (whatever the (Grouping_Level.Sales - Grouping_Level.Costs) calculation returns)
South East SSGP MTDTarget (whatever the (Grouping_Level.Sales - Grouping_Level.Costs) calculation returns)
I require these additional rows added for each Division and Category. There are many Divisions but only the same four Category values for each Division and Grouping_Level.
Requirement 2:
For each Division and Category, again like a Group By, I require a new row creating with the text of 'Gross Profit' added as the Grouping_Level value, and the value field containing the sum (SSGP + FCP + CoS Adj + Customer Rebate + Settlement + Supplier Rebate). For example:
Dvision Grouping_Level Category Value
South West Gross Profit DEValue [SSGP] + [FCP] + [CoS Adj] + [Customer Rebate] + [Settlement] + [Supplier Rebate]
South West Gross Profit DETarget [SSGP] + [FCP] + [CoS Adj] + [Customer Rebate] + [Settlement] + [Supplier Rebate]
South West Gross Profit MTDValue [SSGP] + [FCP] + [CoS Adj] + [Customer Rebate] + [Settlement] + [Supplier Rebate]
South West Gross Profit MTDTarget [SSGP] + [FCP] + [CoS Adj] + [Customer Rebate] + [Settlement] + [Supplier Rebate]
I require these additional rows added for each Division and Category. Again, there are many Divisions but only the same four Category values for each Division and Grouping_Level.
Please can someone help me achieve this?
Any help will much appreciated. Thanks in advance.
Hi @Anonymous ,
If it is convenient, could you share your data sample as table format and your desired output so that I can copy your data and test on it.
Best Regards,
Cherry
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the June 2024 Power BI update to learn about new features.
User | Count |
---|---|
98 | |
94 | |
87 | |
70 | |
65 |
User | Count |
---|---|
244 | |
127 | |
119 | |
81 | |
78 |