Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.
Hi All Member,
Currently, I'm stucked on trying to calculate total sales of Combo Product Set base on below Sales table. This sales tables don't have identify of own combo product. MasterItem column can identify it is combo but MasterItem column is base on uniqueID of transaction.
Example below Papa Blazing Combo, unique ID 1, So all sub combo under Papa Blazing Combo "MasterItem" are all 1 but UniqueID 12, it is also Papa Blazing Combo but MasterItem is also 12.
In this case how can we caculate total sales of combo?
Here is the result that I want to calculate.
Solved! Go to Solution.
Hi @VisalSeng ,
Please try:
ComboID =
var _a = [Masterltem]
return
MAXX(FILTER('Table',[UniquelD]=_a),[ProductID])
Final output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @VisalSeng ,
Please try:
ComboID =
var _a = [Masterltem]
return
MAXX(FILTER('Table',[UniquelD]=_a),[ProductID])
Final output:
Best Regards,
Jianbo Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Thanks for your code but it seem that total sale is not follow as result yet. Result that we want is all arrange by main combo and followup by sub combo.
I have an idea but I'm not sure how dax work yet. I want to create a new column "ComboID" as below. If we can create new column by Dax code to generate ComboID base on Product ID of Main Combo and apply to main combo and sub combo, I think we can filter and sum sales
@VisalSeng Please Try Below Code
Product Sales =
calculate(sum('Table'[Sale]),allexcept('Table'[Product Name]))
@VisalSeng Did I answer your question? Mark my post as a solution! Appreciate your Kudos !! Happy to help!!
@Mahesh0016 It is not yet as result show. May you help to guide me as how to add as yellow colmn instead?
Check out the November 2023 Power BI update to learn about new features.
Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.