Take the 2-minute tour ×
Web Applications Stack Exchange is a question and answer site for power users of web applications. It's 100% free, no registration required.

I have two spreadsheets and would like to enter a value into cell A1, have it check multiple columns in a spreadsheet named 'data' and output information from other columns if it's a match.

----------------------------------------------
|  J. Smith  |   1    |     2     |   ABC    |
----------------------------------------------
|  A. Smith  |   2    |     3     |   DEF    |
----------------------------------------------

I was able to write the following to check only one column but can't seem to get an 'or' statement to work:

=query(data!A:B;"select A,D where B ="&A1;1)
share|improve this question

1 Answer 1

I don't think your formula works at all, so I'm rather guessing what is required but would suggest you label your data source and in say D1 enter:

=query(data!A:D;"select A,B,C,D where B ="&$A1;1) 

Output example with A1 = 2:

WA54928 example

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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