Forum Discussion

kilala's avatar
kilala
Resolver I
4 years ago
Solved

Conditional Calculation Based on Category

Hi all,    I have quite complicated logic that I need to apply.   In his scenario, I have table Brand with their revenue amount.    I need to re-allocate "Default" to brand where revenue > 0, e...
  • v-zhangti's avatar
    4 years ago

    Hi, kilala 

     

    You can try the following methods.

    Measure =
    IF (
        SELECTEDVALUE ( 'Table'[Brand] ) = "D",
        SELECTEDVALUE ( 'Table'[Amount] ),
        IF (
            SELECTEDVALUE ( 'Table'[Amount] ) > 0,
            -1000,
            SELECTEDVALUE ( 'Table'[Amount] )
        )
    )
    

     

    Best Regards,

    Community Support Team _Charlotte

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.