Skip to main content
Question

Nesting more than 2 IF statements in formula

  • October 25, 2026
  • 1 reply
  • 31 views

elmiam

I am having trouble nesting 6 IF statements. It allows me to do so and save it, but when I click back in, only the first two IFs appear – the rest of have erased. Here’s what the formula looks like when I click back in:

 

IF({CS} < 14,

 0,

 IF({CS} > 13,

   AND({CS} < 17),

   1)

)

 

^ When this happens, the formula is working – but only for what’s showing up. The other four IFs I want in play are:

 

 IF({CS} > 16,

   AND({CS} < 20),

   2

 

 

 IF({CS} > 19,

   AND({CS} < 23),

   3

 

 

 IF({CS} > 22,

   AND({CS} < 20),

   4

 

 

 IF({CS} > 25,

   5

 

 

Any tips? I have read a lot of other community posts and guidelines, but I am not seeing this same problem come up anywhere – where it seems to work, but not quite. Thanks!

1 reply

VikasVimal
Forum|alt.badge.img+12

The issue is the formula structure, not the number of IF statements. Each IF() needs a condition, a true result, and a false result. And you only need 5 If statements for 6 outputs.

Use this:

IF({CS}<14,0,
IF({CS}<17,1,
IF({CS}<20,2,
IF({CS}<23,3,
IF({CS}<26,4,5)))))

No AND() is needed because each IF checks the next range in sequence automatically.

I also corrected your fourth condition (>22 and <20), which could never be true.