Forum Discussion
Novice_PBI
7 years agoFrequent Visitor
How to divide a column by a value located in a relationed table
I'm new using Power BI, I'm trying to divide a column by a value located in another relationed table, I used a related command, but I couldn't use a filter to find the value I wanted, I need some com...
- 7 years ago
Hi Novice_PBI
You may use FILTER Function like below:
Value_C = CALCULATE(SUM(Table1[value]),FILTER(Table1,Table1[name]="c"))
Regards,
Cherie
v-cherch-msft
Microsoft Employee
7 years agoHi Novice_PBI
You may check the relationship and create a measure like below.Attached sample file for your reference.
Measure = SUM(Table1[value])/SUM(Table2[value])
Regards,
Cherie
Novice_PBI
7 years agoFrequent Visitor
Thanks for the answer, but I’d like to clarify that the value in the other related table is located in just one of the all cell, so I think I’ll need to use a filter. In that case which command do I have to use?
- v-cherch-msft7 years ago
Microsoft Employee
Hi Novice_PBI
You may use FILTER Function like below:
Value_C = CALCULATE(SUM(Table1[value]),FILTER(Table1,Table1[name]="c"))
Regards,
Cherie