lundi 18 mai 2015

How to nest if and or not Excel

I'm struggling with the following:

I have price ranges from

  • 100 - 200
  • 201 - 300
  • 301 - 400
  • 401 - 500
  • 501 - 600

In every range I give a number from 1-5. I'm trying to give a a number from 1 to 5 to a cell that will check in which price range is.

For example if I write in price field 150 it has to give me to the cell with the formula the number 1 according to the ranges I have. So far I've tried the following but I cannot nest more than 3 ifs.

=IF(AND(B9>=A10,B9<=C10),"1",(IF(AND(B9>=A11,B9<=C11),"2",IF(B9>=A12,B9<=C12,"3"))))

Aucun commentaire:

Enregistrer un commentaire