简体   繁体   中英

VLOOKUP a value to the left of the Lookup_value

Using Excel, is there any way to use the VLOOKUP function to find the date corresponding the minimum and maximum values?

在此处输入图片说明

With your layout @Mark is correct (you can't) and for the reason stated. INDEX/MATCH may be a suitable alternative but to provide some detail, please try in say I30 copied across and down to suit:

 =INDEX($H$6:$H$26,MATCH(I27,I$6:I$26,0))

No, there is no way to look left using VLOOKUP - it can only look right. You should look at INDEX/MATCH combo to solve this.

If you're willing to use a helper column to hold the date, you can. In my example I added the helper column in column N. So column N also displays the date from column H .

=VLOOKUP(I27;$I$6:$O$26;7;0)
=VLOOKUP(I28;$I$6:$O$26;7;0)
...

There is an easy solution for this - if you don't insist on using VLOOKUP() :-)

  1. Above your row 27 enter a new row, repeating the column headings ("Thomson" etc.). You can just use =I5 , =J5 and so on.
  2. Now enter this formula in I30: =DGET($H$5:$N$26;1;J27:J28) ... and drag it to the right.
  3. For the maximum values you need to repeat the column headings just above the "maximum" row again.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM