Forum Discussion

DagdasAlbag's avatar
DagdasAlbag
Helper I
4 years ago
Solved

Dax function "IF"

Hello all,   how do I get the last two columns in row 3 (year: 2020) without values? It should look like on the picture 2.   Unfortunately it does not work with the following Dax function: Abw...
  • v-janeyg-msft's avatar
    v-janeyg-msft
    4 years ago

    Hi, DagdasAlbag 

     

    Column names can't be used directly in measure, you need to use aggregate functions like max() min() selectedvalue() etc....

    Like this:

    RETURN IF(selectedvalue(table[Year])=2020, BLANK(),result_)

     

     Best Regards,
    Community Support Team _ Janey
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.