Forum Discussion
Weighted Average Slicer Selection
Since you just have 5-6 options, you can make measures for each option. Once you have made those 5-6 measures, you can use the technique I described in my blog straightaway.
Although if it was excel, I think I would have done it differently as I can actually enter the values that I want for the weights
- GTR10 years agoHelper III
I have made 5 measures for each option in my FACT table but it returns an error in the msr_value calculation:
"the sum function only accepts a column reference as the argument number 1"
MSR_VALUE: = SWITCH( TRUE,
MIN(MSR[MSR_ID])=1,
SUM(FACT[MEASURE_1]),
MIN(MSR[MSR_ID])=2,
SUM(FACT[MEASURE_2]),
MIN(MSR[MSR_ID])=3,
SUM(FACT[MEASURE_3]),
MIN(MSR[MSR_ID])=4,
SUM(FACT[MEASURE_4]),
MIN(MSR[MSR_ID])=5,
SUM(FACT[MEASURE_5]))- SqlJason10 years agoMemorable Member
You already have the measures, so you don't need to wrap SUM around it. It should just be [Measure_1]and not sum(Fact[Measure_1])