I have spreadsheet with 2 columns - names and values, say:

  • John 2
  • Doe 8
  • Mary 17
  • John 5
  • Bill 12
  • Mary 6
  • John 3

What formula can I use to find the maximum value for each name? (E.g. in column C in each row with John would be 5, with Mary - 17, etc.).

1 Answer 1


In my opinion simplest by far but offering much more than just what you ask is a pivot table:

WA103533 example

You could though try:

=query(I:J,"select I, max(J) group by I")

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.