Search code examples
google-sheetsgoogle-sheets-formula

How to find value vertically and horizontally, using formula in Sheets?


There has to be a couple of matches in a column and in the rows, so that the column header can be obtained, but I cannot do HLOOKUP and VLOOKUP at the same time.

I could do it via script, but if this requires maintenance, that would be harder to keep.

Here is the criteria set:

enter image description here

This is what the Pontuação column should show as the result:

enter image description here

Here is the link to the file: https://docs.google.com/spreadsheets/d/1gh5w0czg2JuoA3i5wPu8_eOpC4Q4TXIRhmUrg53nKMU/edit?usp=sharing


Solution

  • Here's a possible solution:

    =ARRAYFORMULA(MAP(O3:O7;LAMBDA(a;TEXTJOIN(;;IF(B3:F=a;B2:F2;)))))