IF function

Hi !!

My IF function never works so I need some help :)

I have a spreadsheet with columns for Item description (column B) and Item No.(column B) I'd like to populate the Item No automatically maybe using IF function, for example:

IF "B1" = ball then "A1" = 1000, IF "B1" = pen then "A1" = 2000, IF "B1" = bottle then "A1" = 3000

How should I do it ??

Thank you.

Nick's picture

there's one case you

there's one case you missed... if it equals something else.

Here's a function that does what u want, and returns "ERROR" if it equals something else.

=IF(B1="ball",1000,IF(B1="pen",2000,IF(B1="bottle",3000,"ERROR")))