Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
GL GL is offline
external usenet poster
 
Posts: 4
Default Insert value based on range

Here is what I'm trying to accomplish...I want a formula that will populate
the rate based on the employee's age...
So I want it to compare column C to the range in column A and return the
rate from column B to Column D.

As far as I can tell, there are too many options to use nested IF
statements. Can anyone help?

A B C D
Age Employee EE Age Rate
0-24 $0.05 33 0.08
25-29 $0.06
30-34 $0.08
35-39 $0.09
40-44 $0.10
45-49 $0.15
50-54 $0.23
55-59 $0.44
60-64 $0.68
65-69 $1.27
70+ $2.06

  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8,856
Default Insert value based on range

I would set your table up slightly differently so that you have only
the start age in column A, like this:

A B C D
Age Employee EE Age Rate
0 $0.05 33 0.08
25 $0.06
30 $0.08
35 $0.09
40 $0.10
45 $0.15
50 $0.23
55 $0.44
60 $0.68
65 $1.27
70 $2.06

Then in D2 you can have this formula:

=VLOOKUP(C2,A$2:B$12,2)

Hope this helps.

Pete


On Oct 29, 8:40*pm, GL wrote:
Here is what I'm trying to accomplish...I want a formula that will populate
the rate based on the employee's age...
So I want it to compare column C to the range in column A and return the
rate from column B to Column D.

As far as I can tell, there are too many options to use nested IF
statements. *Can anyone help?

A * * * * * * * B * * * * * * * C * * * * * * *D
Age * * Employee * * * *EE Age *Rate
0-24 * *$0.05 * 33 * * *0.08
25-29 * $0.06
30-34 * $0.08
35-39 * $0.09
40-44 * $0.10
45-49 * $0.15
50-54 * $0.23
55-59 * $0.44
60-64 * $0.68
65-69 * $1.27
70+ * * $2.06


  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,696
Default Insert value based on range

you'll want VLOOKUP, but get rid of the -24 stuff.

so:

0
25
30
35
40
etc

for ages

Then =VLOOKUP(C2,A:B,2) will return your rate.

Cleanest way to get rid of the -'s is

Highlight column A

Find -*

Replace With and leave the box blank

Replace all

Then just manually get rid of the + at the end


"GL" wrote:

Here is what I'm trying to accomplish...I want a formula that will populate
the rate based on the employee's age...
So I want it to compare column C to the range in column A and return the
rate from column B to Column D.

As far as I can tell, there are too many options to use nested IF
statements. Can anyone help?

A B C D
Age Employee EE Age Rate
0-24 $0.05 33 0.08
25-29 $0.06
30-34 $0.08
35-39 $0.09
40-44 $0.10
45-49 $0.15
50-54 $0.23
55-59 $0.44
60-64 $0.68
65-69 $1.27
70+ $2.06

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 15,768
Default Insert value based on range

Split your age range into 2 cells:

0-24

Should be:

0.....24

Where 0 is in one cell and 24 is another cell.

With your last boundary ,70+, enter it simply as 70.

Then you do a lookup on the *lower boundary* age range of cells.

Assume:

A1:11 = lower age boundary
B1:B11 = upper age boundary
C1:C11 = numeric values

D1 = 33

=VLOOKUP(D1,A1:C11,3)

--
Biff
Microsoft Excel MVP


"GL" wrote in message
...
Here is what I'm trying to accomplish...I want a formula that will
populate
the rate based on the employee's age...
So I want it to compare column C to the range in column A and return the
rate from column B to Column D.

As far as I can tell, there are too many options to use nested IF
statements. Can anyone help?

A B C D
Age Employee EE Age Rate
0-24 $0.05 33 0.08
25-29 $0.06
30-34 $0.08
35-39 $0.09
40-44 $0.10
45-49 $0.15
50-54 $0.23
55-59 $0.44
60-64 $0.68
65-69 $1.27
70+ $2.06



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Narrow Range based on Selection in Another Range David Excel Discussion (Misc queries) 3 July 1st 07 05:12 PM
Referencing a named range based upon Range name entry in cell Barb Reinhardt Excel Worksheet Functions 14 June 20th 07 07:19 PM
Macro to insert a formula based on a range MarcusA Excel Discussion (Misc queries) 1 December 8th 06 09:26 AM
Count cells in one range based on parameters in another range dave roth Excel Worksheet Functions 2 March 29th 05 05:33 PM
Define a range based on another named range Basil Excel Worksheet Functions 2 February 21st 05 01:47 PM


All times are GMT +1. The time now is 02:30 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"