Ken's Lotto Syndicate

Powerball Syndicate Home Page

Site Tools


google_sheets

This is an old revision of the document!


QUERY to Find Nth Occurrence in Google Sheets

To find the second occurrence of “Mango” in column A and get the corresponding value from column B, you can use the following QUERY formula:

=QUERY(A1:B, "SELECT B WHERE A='Mango' LIMIT 1 OFFSET 1", 0)
</code.
If your data has a header row, you should use it as follows:
<code>
=QUERY(A1:B, "SELECT B WHERE A='Mango' LIMIT 1 OFFSET 1 LABEL B'' ", 1)
google_sheets.1737323282.txt.gz · Last modified: (external edit)