ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   lookup going left based on function (https://www.excelbanter.com/excel-worksheet-functions/38159-lookup-going-left-based-function.html)

Ted Metro

lookup going left based on function
 
I have a table that looks something like this starting at A1

bob 6
dave 2
mike 8
greg 9
chris 1

I want to find the largest value in column b and find the name associated
with that value.

So I can use large(a1:a5,1) to get the largest value, but I can't integrate
that into the lookup formula to get the name because the data isn't sorted.
I've also tried using the address and offset functions, but I can't get it to
work. This has to be pretty easy.

Any ideas from the Excel gurus?
Ted

bj

try
=index(A:A,match(Max(B:B),B:B,0))

"Ted Metro" wrote:

I have a table that looks something like this starting at A1

bob 6
dave 2
mike 8
greg 9
chris 1

I want to find the largest value in column b and find the name associated
with that value.

So I can use large(a1:a5,1) to get the largest value, but I can't integrate
that into the lookup formula to get the name because the data isn't sorted.
I've also tried using the address and offset functions, but I can't get it to
work. This has to be pretty easy.

Any ideas from the Excel gurus?
Ted


Ted Metro

Thank you BJ, I've used that myself to find dates and values. I didn't even
think of using that and just asking index for the first column...well done!

Thanks so much!

"bj" wrote:

try
=index(A:A,match(Max(B:B),B:B,0))

"Ted Metro" wrote:

I have a table that looks something like this starting at A1

bob 6
dave 2
mike 8
greg 9
chris 1

I want to find the largest value in column b and find the name associated
with that value.

So I can use large(a1:a5,1) to get the largest value, but I can't integrate
that into the lookup formula to get the name because the data isn't sorted.
I've also tried using the address and offset functions, but I can't get it to
work. This has to be pretty easy.

Any ideas from the Excel gurus?
Ted



All times are GMT +1. The time now is 07:20 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com