Forum Discussion
sum a column value based on another table column
- Anonymous5 years ago
After modification it works . Thanks Amitchandak .
measure=
var _tab = except(selectcolumns(Table1,"col",Table1[A]),selectcolumns(Table2,"col",Table2[a]))
return
calculate(sum(Table1[b], filter(Table1,Table1[A] in _tab))
Anonymous , Try a measure like
measure=
var _tab = except(allselected(Table1[A]),allselected(Table1[b]))
return
calculate(countrows(Table1), filter(Table1,Table1[A] in _tab))
Thanks for such a quick response , I made a little modification to make it work but the problem is it does not work properly when filter is applied
- Anonymous5 years agoNot applicable
After modification it works . Thanks Amitchandak .
measure=
var _tab = except(selectcolumns(Table1,"col",Table1[A]),selectcolumns(Table2,"col",Table2[a]))
return
calculate(sum(Table1[b], filter(Table1,Table1[A] in _tab))