Forum Discussion

bjerniganpca's avatar
bjerniganpca
Copper Contributor
Mar 27, 2023

Sorting last names alphabetically but keeping together by family ID if last name differs

I have a list of families and each family has a unique identifier called Family ID.  I want to sort the list alphabetically but keep each family together.  Some families do not share the same last na...
  • PeterBartholomew1's avatar
    Mar 29, 2023

    bjerniganpca 

    This is a reasonably simple Excel 365 formula

    = LET(
        leadName, XLOOKUP(ID, ID, Name),
        SORTBY(Tabelle, leadName)
      )

    All it does is identify the first occurring name associated with each ID and sorts on that.

Resources