Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

9 + Parameters, Dax function if two column Variables match!

Writing as a DAX newbie!   I am trying to use 9 Parameters (What if) user inputs to change a measured calculate.   The idea is simple, if there are two variables, like the table below:   Sto...
  • amitchandak's avatar
    5 years ago

    Anonymous , Try a measure like

    Switch(True() ,
    max(Table[Store]) = "A" && max(Table[Product]) = "A", average(Table[AVG. Price])* selectedvalue(Table[param1])
    max(Table[Store]) = "A" && max(Table[Product]) = "B", average(Table[AVG. Price])* selectedvalue(Table[param2])
    max(Table[Store]) = "A" && max(Table[Product]) = "C", average(Table[AVG. Price])* selectedvalue(Table[param3])

    )