Forum Discussion

g-wizard's avatar
g-wizard
Frequent Visitor
2 years ago
Solved

If/AND/ElseIF

Hello Team,  I am having difficulty converting this calc from tableau to pbi dax. Any suggestions? They both come from different tables that are not related. One is an actual table and the other co...
  • lbendlin's avatar
    2 years ago
    a =
    SWITCH (
        Attr[Channel Partner Customer Classification],
        "DM",
            SWITCH (
                TRUE (),
                [Annualized Sales] < 500000, 0,
                [Annualized Sales] < 1000000, 2,
                [Annualized Sales] < 2000000, 3
            ),
        SWITCH (
            TRUE (),
            [Annualized Sales] < 100000, 0,
            [Annualized Sales] < 250000, 2,
            10
        )
    )

     

    Note you have a logic gap in both halfs.