Forum Discussion
Conditional reference to measures/options
- Anonymous3 years ago
In dax there is no else if but we csn put an if inside an if that acts like an else if so you can get
If(max(table[continent]) = "Asia", [coverage],IF(max(table[continent]) = "America",[product],Blank()))
If(max(table[continent]) = "Asia", [coverage],IF(max(table[continent]) = "America",[product],0))
If you want blank for none, use first measure if you want a 0 ,or none use second measure ,or if you have a measure already created for none then just put it instead of 0 or blank()
Thanks for the quick revert.The field Continent has 3 possible values - Product, Coverage, None.
How do we update the logic from ELSE to ELSE If (For the 2nd condition - Not equals product)?
In dax there is no else if but we csn put an if inside an if that acts like an else if so you can get
If(max(table[continent]) = "Asia", [coverage],IF(max(table[continent]) = "America",[product],Blank()))
If(max(table[continent]) = "Asia", [coverage],IF(max(table[continent]) = "America",[product],0))
If you want blank for none, use first measure if you want a 0 ,or none use second measure ,or if you have a measure already created for none then just put it instead of 0 or blank()
- iteronsid3 years agoNew Member
Thanks a lot, cheers!