Forum Discussion

EsgibtkeinBier's avatar
EsgibtkeinBier
Frequent Visitor
4 years ago
Solved

Regarding a (specific) nested IF formula results

  Hey everyone!   I was wondering how the following formula produces results for dates > (2021,3,1), since I can't wrap my head around how it handles stuff after the aforementioned date! Thank you...
  • EsgibtkeinBier's avatar
    4 years ago

    Thanks everyone for suggesting to use SWITCH, as it makes sense both in terms of performance and clarity! However, this does not answer the question of how dates > (2021,3,1) are handled.

     

    With a careful look at the expression above, one can see that only the last logical test involving dates has an else statement, therefore, all dates after the 1st of March 2021, are handled by this part of the expression:

     

      IF(Overview[Publisher]="E",
          0,
          IF(Overview[A]="A",
            DIVIDE(Overview[r],87)*100*0.13,
            If(Overview[A]="V",
              DIVIDE(Overview[i],250),
              Divide(Overview[i],500)