Chapter 22. Boolean operators

Classic search interfaces (that is, those used primarily by librarians) forced users to learn the art of crafting search phrases with Boolean operators. To a large extent this was due to the inability of those systems to provide relevancy ranking beyond a "last in, first out" approach. Thankfully, Evergreen, like most modern search systems, supports a rather sophisticated relevancy ranking system that removes the need for Boolean operators in most cases.

By default, all terms that have been entered in a search query are joined with an implicit AND operator. Those terms are required to appear in the designated fields to produce a matching record: a search for golden compass will search for entries that contain both golden and compass.

Words that are often considered Boolean operators, such as AND, OR, and NOT, are not special in Evergreen: they are treated as just another search term. For example, a title search for golden and compass will not return the title Golden Compass.

However, Evergreen does support Boolean searching for those rare cases where you might require it, using symbolic operators as follows:

Table 22.1. Boolean symbolic operators

Operator Symbol Example



a && b



a || b



a -b