I'm trying to use the contains clause with Excel documents, but it always finds documents without the search phrase. Is it a Microsoft filter issue or am I doing something wrong?
You have an order of precedence problem in your query. A OR B AND C
is the equivalent of A OR (B AND C)
which will match on A
alone - meaning it's matching all files of the specified type. You need to use a sub-clause to introduce the equivalent of parentheses into the query (i.e. you want (A OR B) AND C
).
You can also combine the two Type clauses into a single wildcard, to simplify things a bit:
1 Like