Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,069
Default function to vlookup and put between?

Hi I have a simple table as follow

85 -3
65 -2
55 -1
50 0
45 1
35 2
15 3

I would like to have a formula or function that would allow me to assign a
value based on this table. For example if cell A2 = 47 then that falls
between 45 and 50 on the table and would get a value of 0. if cell A3 = 9
then it would be less than 15 and get a value of 3 (I am rounding down).
Does that make sense? Can someone help?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 265
Default function to vlookup and put between?

Assuming that G2:H8 contains the lookup table, and A2 contains the
lookup value, try...

=INDEX(H2:H8,MATCH(A2,G2:G8,-1))

--
Domenic
Microsoft Excel MVP
www.xl-central.com
Your Quick Reference to Excel Solutions

In article ,
John wrote:

Hi I have a simple table as follow

85 -3
65 -2
55 -1
50 0
45 1
35 2
15 3

I would like to have a formula or function that would allow me to assign a
value based on this table. For example if cell A2 = 47 then that falls
between 45 and 50 on the table and would get a value of 0. if cell A3 = 9
then it would be less than 15 and get a value of 3 (I am rounding down).
Does that make sense? Can someone help?

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
Combine VLOOKUP and IF function so #NA isn't returned as a value from VLOOKUP buffgirl71 Excel Discussion (Misc queries) 12 November 14th 06 11:36 PM
Embedded VLOOKUP function within IF function beautyteknorth Excel Worksheet Functions 6 August 17th 06 09:31 AM
HOW DO I NEST THE VLOOKUP FUNCTION WITH THE LEFT FUNCTION CHAIM Excel Worksheet Functions 1 July 27th 05 09:10 PM
how do I write a vlookup function within an iserror function so t. JBLeeds Excel Worksheet Functions 2 March 16th 05 10:30 AM
I want to use Vlookup function and AND function in a single formu. prakash Excel Worksheet Functions 3 January 25th 05 07:11 AM


All times are GMT +1. The time now is 05:27 AM.

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

About Us

"It's about Microsoft Excel"