Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
trumpy81
 
Posts: n/a
Default Lookup Not working as expected

GDay All,

Can anyone tell me why the folling function is not working correctly.

=LOOKUP(MIN(R10C4:R63C4),R10C4:R63C4,R10C3:R63C3)

The function works only if the lowest value falls within certain cells, but
returns #N/A if the lowest value is in another cell.

Any help would be appreciated.

TIA


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***


  #2   Report Post  
KL
 
Posts: n/a
Default

Hi trumpy81,

As far as I know, LOOKUP only works correctly if the lookup range is sorted
in ascending order 1,2,3, etc. or a,b,c,etc. If you need to lookup in an
unsorted range then you can use VLOOKUP, HLOOKUP (both with the fourth
argument set to 0 or False) or MATCH.

Regards,
KL

"trumpy81" wrote in message
...
GDay All,

Can anyone tell me why the folling function is not working correctly.

=LOOKUP(MIN(R10C4:R63C4),R10C4:R63C4,R10C3:R63C3)

The function works only if the lowest value falls within certain cells,
but returns #N/A if the lowest value is in another cell.

Any help would be appreciated.

TIA


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***



  #3   Report Post  
trumpy81
 
Posts: n/a
Default

KL wrote:
Hi trumpy81,

As far as I know, LOOKUP only works correctly if the lookup range is
sorted in ascending order 1,2,3, etc. or a,b,c,etc. If you need to
lookup in an unsorted range then you can use VLOOKUP, HLOOKUP (both
with the fourth argument set to 0 or False) or MATCH.

Regards,
KL


GDay All,

Thanx KL for the help. I tried using VLOOKUP and HLOOKUP but I seem to get
the same results.

Anybody have any other ideas??

I need to first of all find the lowest value in a column, then display the
contents of the cell beside the cell that contains the lowest value, which
actually contains a name.

The cells actually contain times, as in eg: 9:30:00am.

Any help is certainly appreciated.

Thanx again KL


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***



  #4   Report Post  
CLR
 
Posts: n/a
Default

I dunno for sure (Row and column referencing gives me a headache) but it
looks like you are trying to use VLOOKUP to find the value to the LEFT of
the lookup column......it don't do that, only to the right...........for
example, this formula works...........
=VLOOKUP(MIN(C:C),A:B,2,FALSE)
it finds the minimum value in column C, and looks it up in the range A:B and
returns the value in column B that is appropriate.
it could work also as
=VLOOKUP(MIN(A:A),A:B,2,FALSE)

hth
Vaya con Dios,
Chuck, CABGx3




TK2MSFTNGP12.phx.gbl...
GDay All,

Can anyone tell me why the folling function is not working correctly.

=LOOKUP(MIN(R10C4:R63C4),R10C4:R63C4,R10C3:R63C3)

The function works only if the lowest value falls within certain cells,

but
returns #N/A if the lowest value is in another cell.

Any help would be appreciated.

TIA


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***




  #5   Report Post  
KL
 
Posts: n/a
Default

Hi,

As per CLR note (I didn't notice it as I am not used to R1C1 notation) you
can't use VLOOKUP/HLOOKUP, but you may try this formula:

=INDEX(R10C3:R63C3,MATCH(MIN(R10C4:R63C4),R10C4:R6 3C4,0))

Regards,
KL


"trumpy81" wrote in message
...
KL wrote:
Hi trumpy81,

As far as I know, LOOKUP only works correctly if the lookup range is
sorted in ascending order 1,2,3, etc. or a,b,c,etc. If you need to
lookup in an unsorted range then you can use VLOOKUP, HLOOKUP (both
with the fourth argument set to 0 or False) or MATCH.

Regards,
KL


GDay All,

Thanx KL for the help. I tried using VLOOKUP and HLOOKUP but I seem to get
the same results.

Anybody have any other ideas??

I need to first of all find the lowest value in a column, then display the
contents of the cell beside the cell that contains the lowest value, which
actually contains a name.

The cells actually contain times, as in eg: 9:30:00am.

Any help is certainly appreciated.

Thanx again KL


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***







  #6   Report Post  
trumpy81
 
Posts: n/a
Default

KL wrote:
Hi,

As per CLR note (I didn't notice it as I am not used to R1C1
notation) you can't use VLOOKUP/HLOOKUP, but you may try this formula:

=INDEX(R10C3:R63C3,MATCH(MIN(R10C4:R63C4),R10C4:R6 3C4,0))

Regards,
KL


GDay All,

Once again KL ... THANX!!

That formula did the trick and saved me from a lot of boring/confusing macro
coding!!

It works a treat :)


--
Regards
trumpy81

*** Please remove the `_ spam _' trap before replying to this message ***


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
Lookup Vector > Lookup Value Alec Kolundzic Excel Worksheet Functions 6 June 10th 05 02:14 PM
Hyperlink Function not working as expected Hari Prasadh Excel Discussion (Misc queries) 2 April 16th 05 01:23 PM
Lookup function w/Text and Year Josh O. Excel Worksheet Functions 1 February 12th 05 11:27 PM
Application.Volatile not working as expected Richards Excel Discussion (Misc queries) 3 February 3rd 05 12:20 AM
double lookup, nest, or macro? Josef.angel Excel Worksheet Functions 1 October 29th 04 09:50 AM


All times are GMT +1. The time now is 11:12 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"