Using INDEX MATCH & LARGE to get value in multiple columns

bunny1122

New Member
Joined
Jul 8, 2022
Messages
21
Office Version
  1. 365
Platform
  1. Windows
Hi All

I need to get the largest value(date) for multiple reports in a large dataset and update it in Column B. The Report sample looks like the one from Column E to N.

I'm trying to lookup the figures in Column A and match with the Headers row in the dataset, then get the largest value(date) from the below columns.
I tried to use the INDEX MATCH with LARGE function but it only worked for the first one and return #REF! for the rest and I couldn't figure out how to fix it. Is there also a better way to lookup the whole dataset instead of selecting each column for each report? Appreciate any inputs. Thank you!

Book1
ABCDEFGHIJKLMN
1ReportLast Updatedexpected outputAFS%HSL%ALL%DLL%MLL%
2AFS07-Jun07-Jun03-Jun07-Jun07-Jun07-Jun03-Jun
3HSL#REF!09-Jun03-Jun07-Jun07-Jun07-Jun03-Jun
4ALL#REF!10-Jun04-Jun08-Jun08-Jun08-Jun04-Jun
5DLL#REF!11-Jun04-Jun08-Jun08-Jun08-Jun04-Jun
6MLL#REF!08-Jun05-Jun09-Jun09-Jun09-Jun05-Jun
705-Jun09-Jun09-Jun09-Jun05-Jun
806-Jun09-Jun10-Jun10-Jun06-Jun
906-Jun10-Jun10-Jun06-Jun
1007-Jun11-Jun07-Jun
1111-Jun07-Jun
1208-Jun
1308-Jun
Sheet1
Cell Formulas
RangeFormula
B2B2=INDEX(LARGE(E2:E13,1),MATCH(A2,E1:N1,0))
B3B3=INDEX(LARGE(G2:G13,1),MATCH(A3,E1:N1,0))
B4B4=INDEX(LARGE(I2:I13,1),MATCH(A4,E1:N1,0))
B5B5=INDEX(LARGE(I2:I13,1),MATCH(A5,E1:N1,0))
B6B6=INDEX(LARGE(I2:I13,1),MATCH(A6,E1:N1,0))
Press CTRL+SHIFT+ENTER to enter array formulas.
 

Excel Facts

Show numbers in thousands?
Use a custom number format of #,##0,K. Each comma after the final 0 will divide the displayed number by another thousand
Try:
Book2
ABCDEFGHIJKLMN
1ReportLast Updatedexpected outputAFS%HSL%ALL%DLL%MLL%
2AFS6/7/226/7/226/3/226/7/226/7/226/7/226/3/22
3HSL6/9/226/9/226/3/226/7/226/7/226/7/226/3/22
4ALL6/10/226/10/226/4/226/8/226/8/226/8/226/4/22
5DLL6/11/226/11/226/4/226/8/226/8/226/8/226/4/22
6MLL6/8/226/8/226/5/226/9/226/9/226/9/226/5/22
76/5/226/9/226/9/226/9/226/5/22
86/6/226/9/226/10/226/10/226/6/22
96/6/226/10/226/10/226/6/22
106/7/226/11/226/7/22
116/11/226/7/22
126/8/22
136/8/22
Sheet1
Cell Formulas
RangeFormula
B2:B6B2=MAX(INDEX($E$2:$M$13,0,MATCH($A2,$E$1:$N$1,0)))
 
Upvote 0
Solution
Another way

22 07 20.xlsm
ABCDEFGHIJKLM
1ReportLast Updatedexpected outputAFS%HSL%ALL%DLL%MLL
2AFS07-Jun07-Jun03-Jun07-Jun07-Jun07-Jun03-Jun
3HSL09-Jun09-Jun03-Jun07-Jun07-Jun07-Jun03-Jun
4ALL10-Jun10-Jun04-Jun08-Jun08-Jun08-Jun04-Jun
5DLL11-Jun11-Jun04-Jun08-Jun08-Jun08-Jun04-Jun
6MLL08-Jun08-Jun05-Jun09-Jun09-Jun09-Jun05-Jun
705-Jun09-Jun09-Jun09-Jun05-Jun
806-Jun09-Jun10-Jun10-Jun06-Jun
906-Jun10-Jun10-Jun06-Jun
1007-Jun11-Jun07-Jun
1111-Jun07-Jun
1208-Jun
1308-Jun
14
Max Date
Cell Formulas
RangeFormula
B2:B6B2=MAX(FILTER(E$2:M$20,E$1:M$1=A2))
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,177
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top