Google sheets - find the cell containing specific text
Asked Answered
D

2

1

In Google Sheets, using formulae, is there a way I can search for a certain string in a certain sheet, and return the reference of the cell which contains that string?

The string would be unique to that cell, but the data isn't stored in a list, nor is it sorted

Drome answered 5/9, 2020 at 9:59 Comment(0)
E
2

You can combine FIND or SEARCH (which is case insensitive) into LARGE and ARRAYFORMULA functions:

=ARRAYFORMULA(ADDRESS(LARGE(ISNUMBER(SEARCH(G1,A1:F15))*ROW(A1:F15),1),LARGE(ISNUMBER(SEARCH(G1,A1:F15))*COLUMN(A1:F15),1)))

enter image description here

If search string is not unique in range, it will find last cell that contains string. If you want find first cell, change LARGE to SMALL function.

Ensilage answered 5/9, 2020 at 12:49 Comment(0)
A
0

You can use MATCH(string_to_find, search_range, 0) to find the string and get the row/column number, then ADDRESS() to find the reference to the cell.

Combined, this looks like:

=ADDRESS(MATCH("Cell Text", A1:A, 0), 3)

Note that MATCH() only takes a single row or column so you need to know this beforehand.

Aquavit answered 7/9 at 4:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.