Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hello everyone,
I have a database that when aggregated looks like this:
Product | Color | Sales | % |
Car | Black | 20 | 35.7% |
Bike | 6 | 10.7% | |
Bike | Black | 20 | 35.7% |
Bike | White | 10 | 17.9% |
In the bike product, i have a few bike units without color. And i need to vizualize it without the black cell, but in a way that i don´t lose total sales. Is it possible to distribute the data proportionally inside the same product category?
The output should look like this:
Product | Color | Sales | % |
Car | Black | 20 | 35.7% |
Bike | Black | 24 | 42.9% |
Bike | White | 12 | 21.4% |
Thank you,
Solved! Go to Solution.
Hi @Anonymous
Assume 6 is assigned
2/3 to product bike and color blank, ->20/(20+10)
1/3 to product bike and color white, ->10/(20+10)
Then i create measures
v/c/pr = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]=MAX(Table1[Color]))) sum/c/pr = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]<>BLANK())) per/col/pro = [v/c/pr]/[sum/c/pr] sum/blank/product = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]=BLANK())) result_sale = IF(MAX(Table1[Color])<>BLANK(),MAX(Table1[Sales])+[sum/blank/product]*[per/col/pro]) result_per = [result_sale]/CALCULATE(SUM(Table1[Sales]),ALL(Table1))
Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
Is this problem sloved?
If it is sloved, could you kindly accept it as a solution to close this case?
If not, please let me know.
Best Regards
Maggie
Yes, thank you!
Sry for late reply, i was on vacation.
Hi @Anonymous
Assume 6 is assigned
2/3 to product bike and color blank, ->20/(20+10)
1/3 to product bike and color white, ->10/(20+10)
Then i create measures
v/c/pr = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]=MAX(Table1[Color]))) sum/c/pr = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]<>BLANK())) per/col/pro = [v/c/pr]/[sum/c/pr] sum/blank/product = CALCULATE(SUM(Table1[Sales]),FILTER(ALLEXCEPT(Table1,Table1[Product]),Table1[Color]=BLANK())) result_sale = IF(MAX(Table1[Color])<>BLANK(),MAX(Table1[Sales])+[sum/blank/product]*[per/col/pro]) result_per = [result_sale]/CALCULATE(SUM(Table1[Sales]),ALL(Table1))
Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.