Enterprise Search Keyword Syntax Inclusion and Exclusion

When you specify the property filter in the Enterprise Search in Microsoft Office SharePoint Server 2007 keyword syntax, you must also specify whether the results that are returned should include or exclude content that matches the value specified for that property filter. You accomplish this using Office SharePoint Search keyword syntax inclusion and exclusion characters.

Inclusion and Exclusion Characters

The following table describes the keyword syntax inclusion and exclusion characters.

Name Character Behavior



Include content with values that match the inclusion.



Exclude content with values that match the exclusion.


By definition, property filters are included, so you do not need to use the inclusion character "+". If you do include the character with a property filter, it is ignored. For example, the following syntax fragments behave similarly:

author:"John Smith"
+author:"John Smith"

You can use the exclusion character with a property filter to exclude results from search. This is equivalent to the NOT operator in SQL search syntax. The following syntax fragment shows the use of this character with a property filter:

-author:"John Smith"


The search query must contain at least one included keyword or property filter. If the query contains only an exclusion, it fails with a QueryContainsOnlyExcludedTerms exception.

See Also


Enterprise Search Keywords
Enterprise Search Property Filters