#1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 90
Default Lookup

I am trying to lookup values in a row within a table (*below). This table is
For a 'range' which a returned value must fall into as follows:

A B
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00

For Example if a row has the values: I12 1.84 M12 3.01 O12 2.98 I need to
return the value of 2.00.

Will a lookup tabl eor if stmts work, Any thoughts?

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Lookup

Try this:

=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)

I think this is what you require.

Hope this helps.

Pete

On Sep 23, 2:57*pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). *This table is
For a 'range' which a returned value must fall into as follows:

A * * * * * * *B
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00

For Example if a row has the values: I12 1.84 * M12 3.01 O12 2.98 *I need to
return the value of 2.00.

Will a lookup tabl eor if stmts work, Any thoughts?


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 90
Default Lookup


Receiving a #N/A error but we're closer!

"Pete_UK" wrote:

Try this:

=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)

I think this is what you require.

Hope this helps.

Pete

On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). This table is
For a 'range' which a returned value must fall into as follows:

A B
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00

For Example if a row has the values: I12 1.84 M12 3.01 O12 2.98 I need to
return the value of 2.00.

Will a lookup tabl eor if stmts work, Any thoughts?



  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Lookup

Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?

Pete

On Sep 23, 4:18*pm, Fred wrote:
Receiving a #N/A error but we're closer!



"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). *This table is
For a 'range' which a returned value must fall into as follows:


A * * * * * * *B
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


For Example if a row has the values: I12 1.84 * M12 3.01 O12 2.98 *I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -


  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 90
Default Lookup

Actually, if I compare only one number to those within the table as follows:

8.70 (*Again less than 8.99 but greater than 5.00)

Will the formula change to = vlookup(O8,A$1:B$6,2)?

And yes how do I work a number outside the range?

"Pete_UK" wrote:

Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?

Pete

On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!



"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). This table is
For a 'range' which a returned value must fall into as follows:


A B
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00


For Example if a row has the values: I12 1.84 M12 3.01 O12 2.98 I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -





  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Lookup

Yes, that is correct, although you now seem to be using row 8 rather
than 12.

If the number is greater than 9 (at one end of the range) the formula
will still pick up the corresponding value from 9, i.e. 6.00. But, if
the value is less than 2.99 (at the other end of the range), it will
give rise to that error. There are a few things that you could do, eg:

=VLOOKUP(MAX(I8,M8,O8,2.99),A$1:B$6,2)

will choose 2.99 as the lookup value if the other values are all less
than this, so it will choose the lowest value from your table.

Another way would be:

= IF(O8<A$1,"out of range",VLOOKUP(O8,A$1:B$6,2))

(not using the MAX function here), where you could change the "out of
range" to some other value (like -1).

Alternatively still, you could insert a new row at the top of your
table and put in a lower value there, like:

A B
0.00 0.00
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00

and then the formula would become:

= VLOOKUP(O8,A$1:B$7,2)

Hope this helps.

Pete


On Sep 23, 5:25*pm, Fred wrote:
Actually, if I compare only one number to those within the table as follows:

8.70 *(*Again less than 8.99 but greater than 5.00)

Will the formula change to = vlookup(O8,A$1:B$6,2)?

And yes how do I work a number outside the range?



"Pete_UK" wrote:
Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?


Pete


On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!


"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). *This table is
For a 'range' which a returned value must fall into as follows:


A * * * * * * *B
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


For Example if a row has the values: I12 1.84 * M12 3.01 O12 2.98 *I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -


  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 90
Default Lookup


Closer, but I'm receiving 0.00 as the result?

Here is the formula:
=VLOOKUP(MAX(I7,K7,M7,2.99),O$38:P$43,2)

Thank you!

"Pete_UK" wrote:

Yes, that is correct, although you now seem to be using row 8 rather
than 12.

If the number is greater than 9 (at one end of the range) the formula
will still pick up the corresponding value from 9, i.e. 6.00. But, if
the value is less than 2.99 (at the other end of the range), it will
give rise to that error. There are a few things that you could do, eg:

=VLOOKUP(MAX(I8,M8,O8,2.99),A$1:B$6,2)

will choose 2.99 as the lookup value if the other values are all less
than this, so it will choose the lowest value from your table.

Another way would be:

= IF(O8<A$1,"out of range",VLOOKUP(O8,A$1:B$6,2))

(not using the MAX function here), where you could change the "out of
range" to some other value (like -1).

Alternatively still, you could insert a new row at the top of your
table and put in a lower value there, like:

A B
0.00 0.00
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00

and then the formula would become:

= VLOOKUP(O8,A$1:B$7,2)

Hope this helps.

Pete


On Sep 23, 5:25 pm, Fred wrote:
Actually, if I compare only one number to those within the table as follows:

8.70 (*Again less than 8.99 but greater than 5.00)

Will the formula change to = vlookup(O8,A$1:B$6,2)?

And yes how do I work a number outside the range?



"Pete_UK" wrote:
Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?


Pete


On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!


"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below). This table is
For a 'range' which a returned value must fall into as follows:


A B
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00


For Example if a row has the values: I12 1.84 M12 3.01 O12 2.98 I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -



  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Lookup

It might be that those "numbers" (either in your table or in cells I7,
K7 and M7 - you keep changing the row!!), are not really numbers but
are text values. If it is the 3 individual cells then the MAX function
will return 2.99 so the VLOOKUP function will return 0 - test this out
by changing the 2.99 to another value in your table and see what you
get. In order to find a match the numbers must be proper numbers.

Hope this helps.

Pete

On Sep 23, 6:36*pm, Fred wrote:
Closer, but I'm receiving 0.00 as the result?

Here is the formula:
=VLOOKUP(MAX(I7,K7,M7,2.99),O$38:P$43,2)

Thank you!



"Pete_UK" wrote:
Yes, that is correct, although you now seem to be using row 8 rather
than 12.


If the number is greater than 9 (at one end of the range) the formula
will still pick up the corresponding value from 9, i.e. 6.00. But, if
the value is less than 2.99 (at the other end of the range), it will
give rise to that error. There are a few things that you could do, eg:


=VLOOKUP(MAX(I8,M8,O8,2.99),A$1:B$6,2)


will choose 2.99 as the lookup value if the other values are all less
than this, so it will choose the lowest value from your table.


Another way would be:


= IF(O8<A$1,"out of range",VLOOKUP(O8,A$1:B$6,2))


(not using the MAX function here), where you could change the "out of
range" to some other value (like -1).


Alternatively still, you could insert a new row at the top of your
table and put in a lower value there, like:


A * * * * *B
0.00 * *0.00
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


and then the formula would become:


= VLOOKUP(O8,A$1:B$7,2)


Hope this helps.


Pete


On Sep 23, 5:25 pm, Fred wrote:
Actually, if I compare only one number to those within the table as follows:


8.70 *(*Again less than 8.99 but greater than 5.00)


Will the formula change to = vlookup(O8,A$1:B$6,2)?


And yes how do I work a number outside the range?


"Pete_UK" wrote:
Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?


Pete


On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!


"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below).. *This table is
For a 'range' which a returned value must fall into as follows:


A * * * * * * *B
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


For Example if a row has the values: I12 1.84 * M12 3.01 O12 2.98 *I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -


  #9   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 90
Default Lookup

Hi Pete,

I'm actually going to compare one value to the same table.

=VLOOKUP(H8,I$290:J$296,2)

I J
0.00 0.00
0.03 0.00
0.03 0.02
0.05 0.02
0.05 0.04
0.09 0.04
0.09 0.06

But if I have a negative value, how do I adjust my table or do I add, 2.99
within the formula?

Thanks,
Fred

"Pete_UK" wrote:

It might be that those "numbers" (either in your table or in cells I7,
K7 and M7 - you keep changing the row!!), are not really numbers but
are text values. If it is the 3 individual cells then the MAX function
will return 2.99 so the VLOOKUP function will return 0 - test this out
by changing the 2.99 to another value in your table and see what you
get. In order to find a match the numbers must be proper numbers.

Hope this helps.

Pete

On Sep 23, 6:36 pm, Fred wrote:
Closer, but I'm receiving 0.00 as the result?

Here is the formula:
=VLOOKUP(MAX(I7,K7,M7,2.99),O$38:P$43,2)

Thank you!



"Pete_UK" wrote:
Yes, that is correct, although you now seem to be using row 8 rather
than 12.


If the number is greater than 9 (at one end of the range) the formula
will still pick up the corresponding value from 9, i.e. 6.00. But, if
the value is less than 2.99 (at the other end of the range), it will
give rise to that error. There are a few things that you could do, eg:


=VLOOKUP(MAX(I8,M8,O8,2.99),A$1:B$6,2)


will choose 2.99 as the lookup value if the other values are all less
than this, so it will choose the lowest value from your table.


Another way would be:


= IF(O8<A$1,"out of range",VLOOKUP(O8,A$1:B$6,2))


(not using the MAX function here), where you could change the "out of
range" to some other value (like -1).


Alternatively still, you could insert a new row at the top of your
table and put in a lower value there, like:


A B
0.00 0.00
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00


and then the formula would become:


= VLOOKUP(O8,A$1:B$7,2)


Hope this helps.


Pete


On Sep 23, 5:25 pm, Fred wrote:
Actually, if I compare only one number to those within the table as follows:


8.70 (*Again less than 8.99 but greater than 5.00)


Will the formula change to = vlookup(O8,A$1:B$6,2)?


And yes how do I work a number outside the range?


"Pete_UK" wrote:
Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?


Pete


On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!


"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below).. This table is
For a 'range' which a returned value must fall into as follows:


A B
2.99 0.00
3.00 2.00
4.99 2.00
5.00 4.00
8.99 4.00
9.00 6.00


For Example if a row has the values: I12 1.84 M12 3.01 O12 2.98 I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -



  #10   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,856
Default Lookup

Your table seems to have changed quite a bit from the one you first
posted, and now you have duplicate values in column I - VLOOKUP will
only find the first of these.

Anyway, you could do this to trap -ve values:

=IF(H8<0,0,VLOOKUP(H8,I$290:J$296,2))

This will return 0 - I'm not sure what the 2.99 refers to now.

Hope this helps.

Pete

On Sep 29, 4:41*pm, Fred wrote:
Hi Pete,

I'm actually going to compare one value to the same table.

=VLOOKUP(H8,I$290:J$296,2)

I * * * * * * * J
0.00 * *0.00
0.03 * *0.00
0.03 * *0.02
0.05 * *0.02
0.05 * *0.04
0.09 * *0.04
0.09 * *0.06

But if I have a negative value, how do I adjust my table or do I add, 2.99
within the formula?

Thanks,
Fred



"Pete_UK" wrote:
It might be that those "numbers" (either in your table or in cells I7,
K7 and M7 - you keep changing the row!!), are not really numbers but
are text values. If it is the 3 individual cells then the MAX function
will return 2.99 so the VLOOKUP function will return 0 - test this out
by changing the 2.99 to another value in your table and see what you
get. In order to find a match the numbers must be proper numbers.


Hope this helps.


Pete


On Sep 23, 6:36 pm, Fred wrote:
Closer, but I'm receiving 0.00 as the result?


Here is the formula:
=VLOOKUP(MAX(I7,K7,M7,2.99),O$38:P$43,2)


Thank you!


"Pete_UK" wrote:
Yes, that is correct, although you now seem to be using row 8 rather
than 12.


If the number is greater than 9 (at one end of the range) the formula
will still pick up the corresponding value from 9, i.e. 6.00. But, if
the value is less than 2.99 (at the other end of the range), it will
give rise to that error. There are a few things that you could do, eg:


=VLOOKUP(MAX(I8,M8,O8,2.99),A$1:B$6,2)


will choose 2.99 as the lookup value if the other values are all less
than this, so it will choose the lowest value from your table.


Another way would be:


= IF(O8<A$1,"out of range",VLOOKUP(O8,A$1:B$6,2))


(not using the MAX function here), where you could change the "out of
range" to some other value (like -1).


Alternatively still, you could insert a new row at the top of your
table and put in a lower value there, like:


A * * * * *B
0.00 * *0.00
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


and then the formula would become:


= VLOOKUP(O8,A$1:B$7,2)


Hope this helps.


Pete


On Sep 23, 5:25 pm, Fred wrote:
Actually, if I compare only one number to those within the table as follows:


8.70 *(*Again less than 8.99 but greater than 5.00)


Will the formula change to = vlookup(O8,A$1:B$6,2)?


And yes how do I work a number outside the range?


"Pete_UK" wrote:
Is the maximum value of those 3 cells less than 2.99, so that it is
outside the range of the table?


Pete


On Sep 23, 4:18 pm, Fred wrote:
Receiving a #N/A error but we're closer!


"Pete_UK" wrote:
Try this:


=VLOOKUP(MAX(I12,M12,O12),A$1:B$6,2)


I think this is what you require.


Hope this helps.


Pete


On Sep 23, 2:57 pm, Fred wrote:
I am trying to lookup values in a row within a table (*below).. *This table is
For a 'range' which a returned value must fall into as follows:


A * * * * * * *B
2.99 * *0.00
3.00 * *2.00
4.99 * *2.00
5.00 * *4.00
8.99 * *4.00
9.00 * *6.00


For Example if a row has the values: I12 1.84 * M12 3.01 O12 2.98 *I need to
return the value of 2.00.


Will a lookup tabl eor if stmts work, Any thoughts?- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -- Hide quoted text -


- Show quoted text -


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
Matrix lookup/mulitple criteria lookup MarkFranklin Excel Discussion (Misc queries) 3 March 31st 08 10:15 AM
Get Cell Address From Lookup (Alternative to Lookup) ryguy7272 Excel Worksheet Functions 12 September 28th 07 10:36 PM
Join 2 Lists - Lookup value in 1 list & use result in 2nd lookup JBush Excel Worksheet Functions 3 January 3rd 07 11:14 PM
Sumproduct - Condition based on lookup of a Lookup Hari Excel Discussion (Misc queries) 12 May 31st 06 09:28 AM
Pivot table doing a lookup without using the lookup function? NGASGELI Excel Discussion (Misc queries) 0 August 2nd 05 05:08 AM


All times are GMT +1. The time now is 05:38 PM.

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"