Explanation

In the example shown, cell G4 contains the lookup value, “Berlin”.

XLOOKUP is configured to find this value in the table, and return the population.

The formula in G5 is:

To return County instead of population, only the return array is changed.

Excel formula: XLOOKUP with multiple criteria

XLOOKUP supports approximate and exact matching, wildcards (* ?)

for partial matches, and lookups in vertical or horizontal ranges….

Excel formula: XLOOKUP with logical criteria

Excel formula: XLOOKUP lookup left

Excel formula: INDEX and MATCH exact match

Excel XLOOKUP function