Forum Discussion

olivere91's avatar
olivere91
Icon for Helper I rankHelper I
4 years ago
Solved

Profit Margin with exception

Hello,   I have a matrix, in the matrix, there are columns to show Margin, Margin %. I have a requirement that says if the department code =Blob then take that margin and subtract 21.5% from it. So...
  • olivere91's avatar
    4 years ago

    I figured it out using this:

     

    GM Dollars =
    SUMX(VALUES(Item_Sales_Profit[Department]),
    SWITCH(Item_Sales_Profit[Department],
    "BLOB",Item_Sales_Profit[BLOB Margin $],
    [GM $]))