Forum Discussion
Anonymous
6 years agoNot applicable
Using RELATED based on multiple columns
Hi, I'm trying to calculate a number bases on different percentages per category. I just can't figure out how to do this properly. Let me explain via an example. There is certain Amount per G...
- 6 years ago
HI Anonymous
Ok, try this measure
Total 2= SUMX('Table 1',[Amount]*CALCULATE(SUM('Table 2'[Percentage])))Result:
and here is sample pbix file, please try it.
Regards,
Lin
Anonymous
6 years agoNot applicable
Thank you for your responses. I feel like I haven't explained correctly what I'm trying to do.
These are simplified versions of the tables:
The relation is Group to Group via a third table with unique Groups-values (* <-> 1, 1 <-> *).
What happens now if I filter Area code "1" and Brand "Batavus":
(518+1561) * (0.1654+0.1604)
What I would like to calculate if I filter Area code "1" and Brand "Batavus" for example:
518 * 0.1654 + 1561 * 0.1604
This way I can show the total Amount * Percentage per Brand
v-lili6-msft
Community Support
6 years agoHI Anonymous
Ok, try this measure
Total 2= SUMX('Table 1',[Amount]*CALCULATE(SUM('Table 2'[Percentage])))
Result:
and here is sample pbix file, please try it.
Regards,
Lin