2

I just about have formula 100% perfect. Just one issue:

Formula (Works):

=QUERY( ImportRange( "https://docs.google.com/spreadsheets/d/1Lf4r_b0fmFh6fClZsGmfZmo8ZD87qf8N_0f-Jaoyu-g/edit#gid=0", "Sheet1!A1:AA1000" ) , 
 "Select Col19 where Col8 = 2917", 0)

Instead of the "Select X Where Y = Z"

I am hoping Z can be a value on the current sheet.

Example: (not working)

=QUERY( ImportRange( "https://docs.google.com/spreadsheets/d/1Lf4r_b0fmFh6fClZsGmfZmo8ZD87qf8N_0f-Jaoyu-g/edit#gid=0", "Sheet1!A1:AA1000" ) , 
 "Select Col19 where Col8 = "Sheet1!F5"", 0)

Sheets sees the reference to Cell F5 but still gives a "Formula parse error"

Can Value Z be a linked cell?

1 Answer 1

2

If the value Z is numeric do:

=QUERY(IMPORTRANGE("1Lf4r_b0fmFh6fClZsGmfZmo8ZD87qf8N_0f-Jaoyu-g", "Sheet1!A1:P1000"), 
 "select Col19 where Col8 = "&Sheet1!F5, 0)


If the value Z is a text string or a mix of text and numbers do:

=QUERY(IMPORTRANGE("1Lf4r_b0fmFh6fClZsGmfZmo8ZD87qf8N_0f-Jaoyu-g", "Sheet1!A1:P1000"), 
 "select Col19 where Col8 = '"&Sheet1!F5&"'", 0)

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.