I have a table like below and I want to return the name of the item with the greatest effect of a particular type. For example, I want the name of the ring with the best 'Shield' enchantment, in this case 'Brusef Amelion's Ring'.
| Description | Apparel slot | Effect Type | Effect Value |
|---|---|---|---|
| Apron of Adroitness | Chest | Fortify Agility | 5 pts |
| Brusef Amelion's Ring | Ring | Shield | 18% |
| Cuirass of the Herald | Chest | Fortify Health | 15 pts |
| Fortify Magicka Pants | Legs | Fortify Magicka | 20 pts |
| Grand ring of Aegis | Ring | Shield | 6% |
I've tried using a MAXIFS statement:
=maxifs(Effect Value, Apparel Slot, "=Ring", Effect Type, "=Shield")
and that returns 0.18, as I'd expect. But I want it to return the name of this item, 'Brusef Amelion's Ring'. So I then tried using a vlookup on this value, but there doesn't seem to be the option to only lookup a value if ('Apparel Slot'='Ring' && 'Effect Type'='Shield'), for example.
I feel like there must be a way of nesting some specific functions here, but I can't quite figure it out.
Is there any way to do this while avoiding manually sorting and filtering my data before running each query?