I have a sheet of data that I've been using query functions in. It has worked great so far for single variables, but now I'm trying to make a query from 2 variables, referencing 2 different drop-down lists.
Right now I'm able to filter by category (Clothing type) and by the employee who onboarded separately, but let's say I want to create a query from a specific employee and category. How would I do that? Right now Im using this formula
=query(Brands!A5:L, " select * where J = '"&B2&"' ")
which does exactly what it's supposed to do.

How would I add a 2nd variable to that function?


1 Answer 1


If im understanding you correctly, you should just be able to add another selector to the query:

=query(Brands!A5:L, " select * where J = '"&B2&"' and [col] = '"&[cell]&"'")

Replacing [col] and [cell] with the proper references.

Please let me know if you have any issues with this

Your Answer

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

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