I am using FILTER()
to display a value from Sheet 2 where the Name
columns match.
My problem is where I want:
=FILTER(Sheet2!A:F, Sheet2!A:A="Combat Medic" OR Sheet2!A:A="Universal")
as OR
results in an error.
What is the correct syntax?
Must I use a QUERY()
instead?
Best Answer
Use the following formula to obtain the query you want.
Formula
Explained
In the reference it is explained by Ahab that
+
and*
can be used as boolean expressions, asOR
andAND
.The solution with the
IFERROR
(see revision history) is of no use in this case, unless you want to find a particular string:Here the
IFERROR
returns0
when nothing is found, causing the formula to still function.Screenshot
Example
I've modified the example file to contain both solutions: Filter with Boolean
Reference
Google Product Forum, Boolean Expressions