IF function help

  • Thread starter Thread starter girth69
  • Start date Start date
G

girth69

Hi,

I need some help creating an IF function. I have a list of salar
brackets e.g A 0 - 10,000
B 10,000 - 20,000
C 20,000 - 30,000
D 30,000 - 40,000
etc

On a seperate spreadsheet i have different cells with peoples salarie
in. In a seperate cell underneath their salary cells, i have an empt
cell that needs to have the relevant letter in that shows which ban
they fall into A,B,C,D etc.

What i need is an IF function in the blank cell that will automaticall
come up when a persons salary is typed in.

E.g : - if i type in 24,000 into the salary cell, i want the blank cel
to then come up with the letter C.

Thank
 
With salary in C1,
Set up a datalist in an out-of- the-way location, say Y1 to Z10, such as
this:

Y Z

0 A
10001 B
20001 C
30001 D
40001 E
.... etc.

Then try this formula in the "empty" cell:

=LOOKUP(C1,Y1:Z10)

--

HTH,

RD
=====================================================
Please keep all correspondence within the Group, so all may benefit!
=====================================================

message
Hi,

I need some help creating an IF function. I have a list of salary
brackets e.g A 0 - 10,000
B 10,000 - 20,000
C 20,000 - 30,000
D 30,000 - 40,000
etc

On a seperate spreadsheet i have different cells with peoples salaries
in. In a seperate cell underneath their salary cells, i have an empty
cell that needs to have the relevant letter in that shows which band
they fall into A,B,C,D etc.

What i need is an IF function in the blank cell that will automatically
come up when a persons salary is typed in.

E.g : - if i type in 24,000 into the salary cell, i want the blank cell
to then come up with the letter C.

Thanks
 
Hi,
The answer given of the vlookup is a nice neat way (as long as you realise you are just asking the formula to find the nearest value).
You were looking for an If formula, well that will only work up to a certain amount of options as there is a mximum number of formula's you can nest together.

E.G.
=IF(C7<=10000,"A",IF(AND(C7>10000,C7<=20000),"B",IF(AND(C7>20000,C7<=30000),"C","D")))

As you can see the If function becomes a little messy when you are looking at a lot of options. I think the VLOOKUP advice is sound and is the way forward but here is the answer to the question you posed.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top