We help IT Professionals succeed at work.

Identify duplicates in a column then find the maximum value of adjacent column values in excel

macentrap
macentrap used Ask the Experts™
on
Hello Experts

Based on duplicates in column A, I am trying to show the  highest value support identifier from values in column 'D'

in attached sample:
Column A : Request reference
Column B : Request task
Column C: Support group
Column D: Support group identifier
Column E: desired result
sample_v2.xlsb
Comment
Watch Question

Do more with

Expert Office
EXPERT OFFICE® is a registered trademark of EXPERTS EXCHANGE®
Subodh Tiwari (Neeraj)Excel & VBA Expert
Most Valuable Expert 2018
Awarded 2015

Commented:
Some of your desired output in column E are confusing.
Try this formula to see if that works for you...

In F2 (next to your desired output column E so that you can compare the outputs)
=IF(COUNTIF(A$2:A2,A2)>1,"",MAXIFS($D$2:$D$2046,$A$2:$A$2046,A2))

Open in new window

and copy it down.

Author

Commented:
thank you

getting Error  : #NAME?
Subodh Tiwari (Neeraj)Excel & VBA Expert
Most Valuable Expert 2018
Awarded 2015

Commented:
That means MAXIFS function is not available with the version you are using.

Try this Array Formula which requires confirmation with Ctrl+Shift+Enter instead of Enter alone.

In F2
=IF(COUNTIF(A$2:A2,A2)>1,"",MAX(IF($A$2:$A$2046=A2,($D$2:$D$2046))))

Open in new window

Confirm with Ctrl+Shift+Enter and copy it down.

Author

Commented:
Thank you Neeraj, worked :)
Please, is it possible to display the result value next to the  'tier lookup' it encountered the value?


Excel version is 2016, sorry forgot to mention earlier
Subodh Tiwari (Neeraj)Excel & VBA Expert
Most Valuable Expert 2018
Awarded 2015

Commented:
You're welcome! Glad it worked as desired.

MINIFS and MAXIFS are only available to subscribers of OFFICE 365 with current version of EXCEL 2016. The standalone version of EXCEL 2016 does not have these new formulas.


MINIFS and MAXIFS are only available to subscribers of OFFICE 365 with current version of EXCEL 2016. The standalone version of EXCEL 2016 does not have these new formulas.
Why not? Just place the formula in E2, confirm it with Ctrl+Shift+Enter and then copy it down.

Author

Commented:
Thank you

Tired to place formula in E2,  but the result is showing earlier than the 'tier lookup' it encountered the value.

have attached the update sample for review with highlighted columns
sample_v3.xlsb
Excel & VBA Expert
Most Valuable Expert 2018
Awarded 2015
Commented:
Try this and see if that works as desired.

In E2
=IF(AND(COUNTIFS(A$2:A2,A2,D$2:D2,MAX(IF($A$2:$A$2046=A2,($D$2:$D$2046))))=1,D2=MAX(IF($A$2:$A$2046=A2,($D$2:$D$2046)))),D2,"")

Open in new window

sample_v3.xlsb

Author

Commented:
Thank you so much Neeraj :)

Author

Commented:
very helpful and speedy response
Subodh Tiwari (Neeraj)Excel & VBA Expert
Most Valuable Expert 2018
Awarded 2015

Commented:
You're welcome again! Glad I could help.