Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hi, I am trying to create a DAX calculation which will display a share of a product on another product flagged as market leader.
Basically, this is it:
Products are filtered based on slicers/categories but it is not a problem. I could calculate the % based on column total, but closest I got in this time was here - values are calculated only for Market Leader.
I use this DAX:
=DIVIDE(
SUM (T_DATA[Value]);
CALCULATE( SUM (T_DATA[Value]);
T_DATA[T_LOV_Product.Competition]=2;
ALLSELECTED(T_LOV_Product)
))
Thank you very much indeed.
Jan
Solved! Go to Solution.
Hello:
Assuming you have the measure for market leader, I'll name it [Market Leader Sales]
You can try
Share of Mkt Leader =
DIVIDE(SUMX(T_Data, T_Data[Value]),
CALCULATE([Market Leader Sales], ALLEXCEPT('T_Data[YYYY_MM]))
Thank you very much!
ALLEXCEPT did not even cross my mind.
Just for somebody who may follow up the final code I used + if necessary add filtering into ALLEXCEPT:
Your welcome:-)
Hello:
Assuming you have the measure for market leader, I'll name it [Market Leader Sales]
You can try
Share of Mkt Leader =
DIVIDE(SUMX(T_Data, T_Data[Value]),
CALCULATE([Market Leader Sales], ALLEXCEPT('T_Data[YYYY_MM]))
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.
| User | Count |
|---|---|
| 8 | |
| 6 | |
| 6 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 25 | |
| 16 | |
| 8 | |
| 7 | |
| 6 |