Return a value from a Google Sheet with an ever changing number of columns

654 views google-spreadsheet
7

I'm trying to return a value from a table that has an inconsistent number and order of columns.

Let's say my table looks something like this:

https://docs.google.com/spreadsheets/d/1fm_-98QS0PhyrDTGDdwma5Z6OFNMhFhnvKBJQ-tKaIA/edit?usp=sharing

What's the best way to return Joe's Age? Again keeping in mind the fact that the "Age" column will change position randomly due to the fact that I'm pulling a dynamic data set, therefore referencing it using "=B4" is no good. The "Age" column will not change in name, so it's safe to search for the correct column number that way, I'm just struggling hard even doing that.

answered question

1 Answer

2

Try,

=index($A:$Z, match("joe", $A:$A, 0), match("age", $1:$1, 0))

That should cover age in any column from A to Z in row 1.

posted this

Have an answer?

JD

Please login first before posting an answer.