Grouping keywords and operators
Another advanced searching technique is the use of parentheses ( )
to create complex logic.
You can group words or phrases by placing them inside parentheses.
Using this technique in combination with operators can give you one search query that both includes and excludes in the same search. This is
a powerful technique. Here is an example of a search query that will find information on professional football team mascots without getting any information on high school or college football team mascots. football AND mascot AND NOT (college OR high)
.
Although this will screen out most unwanted matches, you may still find a small number of results that include high school or college
football teams if the Web page only has the high school or college team name and not the words "high school" or "college."
Each entry typically includes the syntax, the capabilities, and an example. Some of the search operators will not work as intended if you
put a space between the colon (:) and the subsequent query word. If you do not care to check which search operators require no space after the colon, always place the keyword immediately next to the colon.
Many search operators can appear anywhere in your query. In our examples, we place the search operator as far to the right as possible. We do
this because the Advanced Search form writes queries in this way. Also, such a convention makes it clearer as to which operators are
associated with which terms.