Use Lookup, Not Nested If

By Lu


The IF formula is a useful function and often used. A simple binary outcome, TRUE or FALSE, 1 or 0. But because it’s so commonly used that most abused it in the form of NESTED IF.

You saw it before.

 IF(condition1, result1, IF(condition2, result2, IF(condition3, result3, result4)) 

Because the logic is simple here, most defaulted to using Nested IF. I do too, but at some point, enough is enough.

Things become cumbersome if the Nested IF became longer. Over time, more conditions could pop up and a remedy would be to add another enclosed IF to specify that condition.

Logic wise, there’s nothing wrong with nested if but it’s a headache to view at organization level. Imagined having to read a formula with a longer nested if than maybe 7? I encountered a 23 level Nested IF and that was a nightmare.

So, please. Use Lookup instead if there’s a long nested if. It’s simple and much easier to adjust than a long string of formula.