Forum Discussion

RvanMelis's avatar
RvanMelis
Frequent Visitor
4 years ago
Solved

Using IF statement with measure

Hello,    I'm facing issues when i try to make an IF statement in a measure, using measures.  I did some research myself but can't find the proper solution for my problem.    I created a table w...
  • tamerj1's avatar
    4 years ago

    Hi RvanMelis 

    try

     

    OHW op aanneemsom =
    IF (
        NOT ISBLANK ( [Mijlpalen gefactureerd] )
            && NOT ISBLANK ( [Aanneemsom] ) && NOT ISBLANK ( [Totaal realisatie] ),
        IF (
            [Mijlpalen gefactureerd] >= [Aanneemsom],
            0,
            IF (
                [Totaal realisatie] < [Aanneemsom],
                [Totaal realisatie] - [Mijlpalen gefactureerd],
                IF (
                    [Totaal realisatie] >= [Aanneemsom],
                    [Aanneemsom] - [Mijlpalen gefactureerd],
                    0
                )
            )
        )
    )