How helpful was this page?
Related Blog Posts
Improve searching—Medium aliases
Oct 14, 2020
Why can't I find it?—Tips for using Search
Aug 12, 2020
Help!—Researcher training for librarians
May 06, 2020
View Hidden Items in Researcher
Jan 08, 2020
"Elehpants?"—Spell Check for Researcher
Nov 06, 2019
Using Study Programs in Researcher
Oct 30, 2019
Fix Your Series!
Sep 18, 2019
Can't I search by barcode?—Scan-to-list workaround
Sep 12, 2019
Advanced Search & Boolean Logic
Nov 06, 2017
I want what I want—Searching by Genre
Sep 26, 2016
What is boolean?
Boolean is a type of searching named after English mathematician George Boole (1815-64) who founded a field of mathematical and philosophical study called symbolic logic. Whenever you use a system that allows you to use the AND, OR, or AND NOT operators to limit or expand your search, you are actually using Boolean logic.
Boolean operators are already built into the Reports and Utilities tools for Alexandria v7, including the ability to include or exclude multiple policies in the Selections tab for some reports. However, you may elect to use them when searching the library's catalog in Researcher. You may also use a search string in lieu of the Boolean operators when searching for items. For more information about performing a catalog search with Boolean operators you may view our Advanced Search Pane support page.
When searching using multiple criteria on any database or the internet, it is important to know the order in which the search engine will search for the terms you specified. Some search engines will assume that any record that has just one of the criteria is acceptable (this OR that in the record). Others will assume that a record must meet all the criteria to be acceptable (this AND that in the record). Yet others allow you to combine criteria using parentheses or quotes to force a specific order on the search (this AND (that OR those) in the record - all records returned must have (this AND that) OR (this AND those)). It is important that you know how the search engine processes a search in order for you to get back the results you expect.
For Alexandria, you must know four things in order to search effectively.
- If you enter multiple words in an any word search box or in the simple search box, we assume all words must be in the records returned. (AND search)
- Alexandria processes searches from the top search box down to the bottom search box.
- There is no such thing as a parenthetical search at this time in the Alexandria system. You cannot search for ((Black OR Afro OR African American) AND (folklore OR legend)) because it requires parentheses to force a specific processing order. See Precedence Order below.
- Learn the Four Boolean Operators (AND, OR, AND NOT, THROUGH) for Searching within Alexandria to limit and expand your search even more.
The AND operator is a short way of saying that all of the search terms have to be in the records returned. This AND differs from the English "and". In English we might say "I want books on Cats and Dogs" - meaning that any book on cats would be acceptable, any book on dogs would be acceptable, and any book on both cats and dogs would be acceptable. This connotation is the equivalent of the OR operator in Boolean logic. The AND operator would find only books on both cats AND dogs acceptable.
To illustrate this concept, we will use the following diagrams. Imagine that all the records that contain the word cats exist in the circle labeled Cats below and all the records that contain the word dogs exist in the circle labeled Dogs. Those records that had both words, cats AND dogs, exist in the shaded area and are returned when that search (cats AND dogs) is performed. Note that the AND search returns a small number of records.
The OR operator is a short way of saying that just one of the search terms must be included in the records returned. Imagine again that all the records that contain the word "cats" exist in the circle labeled Cats below and all the records that contain the word "dogs" exist in the circle labeled Dogs. The records returned when the search (cats OR dogs) is performed show in the shaded area. They include records that only have the word cats, that only have the word dogs, and that have both words, cats and dogs. Note that the OR search returns a large number of records.
AND NOT operator
The AND NOT operator is a short way of saying that only the first term should be included in the records returned. Imagine again that all the records that contain the word cats exist in the circle labeled Cats below and all the records that contain the word dogs exist in the circle labeled Dogs. The records returned when the search (cats AND NOT dogs) is performed show in the shaded area. They include records that only have the word cats; the word dogs cannot be in any of the records returned. Note that the AND NOT search returns a large number of records and can eliminate unwanted records. Other possible searches where you might use the AND NOT operator include "virus AND NOT AIDS" or "hives AND NOT bees" (to find books on the allergy symptoms and not on the homes of bees).
The Through operator allows the user to specify a range of terms to search in a particular index. For instance, to find all call numbers in the 500 range, you could search for Call Numbers beginning with 50 OR 51 OR 52 OR 53 OR 54 OR 55 etc. Or you could use the Through operator as a shortcut and choose all Call Numbers beginning with 500 Through 599. You could then combine this with other search terms like AND Mars to only get items on Mars in the 500s (items about the planet Mars and not the god Mars).
Precedence order is the rules that a system uses to prioritize which of several searches it should do first. This applies when you have multiple Boolean operators in the same search. The Advanced Search in Researcher has the precedence order of start at the top and work down.
- If your search uses only AND operators, then all words must be in every record returned and it won't matter what order they were entered.
- If your search uses only OR operators, then only one word must be in every record returned and it won't matter what order they were entered.
- However, if your search uses a mixture of AND, OR, or AND NOT operators, the order in which they are entered will determine the results you get.
For example, imagine that you want books on Greek or Roman mythology. If you search Alexandria with Boolean terms for Greek OR Roman AND Mythology, it will first find everything that has the word Greek OR the word Roman AND only keep those records that have the word mythology. The diagram for this search would be this.
But if you enter the search in the opposite order, Mythology AND Roman OR Greek, Alexandria would first search for every record that had the word Mythology AND only keep those that had the word Roman, then add on any record that had the word Greek. This means that all books on Greek history, Greek art, Greek architecture, Greek cooking, OR Greek mythology would be on the list. The diagram for this search would be this.
Because of the precedence order that Alexandria currently uses, if one word belongs in every record returned, it should be the LAST thing searched for (AND search).