Forum Discussion

rpinxt's avatar
rpinxt
Solution Sage
3 years ago
Solved

Why do I get Circular Dependancy

Making calculated columns my first one is this : IF('AVN Rework Merge'[Flow] = "Reworked" && [Amt USD] > -50,[Quantity],0)   It works fine and gives me the quantity that I expected.   Now I want...
  • m_alireza's avatar
    3 years ago

    rpinxt Instead of referencing the measure [FinAmtUSD], try referencing the column directly instead.

    so:

    Reworked USD < 50 = IF('AVN Rework Merge'[Flow] = "Reworked" && 'AVN Rework Merge'[FinAmtUSD] > -50,'AVN Rework Merge'[FinAmtUSD],0)
  • SivaMani's avatar
    SivaMani
    3 years ago

    rpinxt I agree with m_alireza. Also, any specific reason why you went with Calculated Columns instead measures?
    I rewrote the logic as a measure for you. Check if this meets your requirement

    Reworked Qty <50__ = 
    VAR Result = CALCULATE(
         [Quantity],
         FILTER('AVN Rework Merge', 'AVN Rework Merge'[Flow] = "Reworked" &&  [Amt USD] > -50)
         )
    RETURN
    COALESCE(Result,0)