Boolean operators

Direct the search engine with more precision to get the best search results possible.

Boolean operators are short words and characters that can tell the search engine how search terms should relate to each other.

Boolean operators list

  • a AND b: AND tells the search engine to look for both terms.

  • a OR b: OR is used to look for results with either or both terms.

  • a AND NOT b: AND NOT will exclude all results with the second term.

  • "abc": when you write a term or a sentence in quotation marks, the results will contain that exact term or phrase.

  • abc*: using an asterisk instructs the search engine to finish the word.

  • [a b c]: using square brackets lets you search for similar words.

  • [a b c]/N: adding a / followed by a number next to the square brackets will limit how close words are to each other.

In-depth explanation

AND

Sometimes terms can go in the same search, but they are not a phrase. For example, if searching for "urban planning" in the city of Winnipeg, using quotation marks for the whole sentence might miss relevant documents with different phrasing. The solution to this is to use the word AND in all caps to tell the search engine that your results should include both terms. Searching "urban planning" AND Winnipeg yields 47 results.

OR

If you need to expand your search to use more words, you can use OR. OR tells vLex that search results can include either or both terms. Let's use the previous example but say that we're interested in either Winnipeg or Edmonton. You can search "urban planning" AND Winnipeg OR Edmonton. At the time of writing, the results page shows 101 documents, because it has added results including the word Edmonton.

AND NOT

Sometimes search results might include terms we do not want. In this case, we can use the operator AND NOT. For our example, to avoid results that include housing, the search would be "urban planning" AND Winnipeg AND NOT housing. Now, the results are down to 18.

"abc"

The easiest way to group words is by putting them between quotation marks. This will tell the search engine to consider the phrase as one unit. For example, just searching for urban planning will yield results with urban and planning anywhere in the document, as well as documents containing just urban or just planning. Using quotation marks will ensure you search for the words ''urban planning'' together, in that order. This will vastly reduce your results and the most relevant documents will be found. For example, when writing this, urban planning yields 78,388 results, whilst "urban planning" yields 8,851.

abc*

Sometimes you know only part of a word or a name. If you use an asterisk, the search engine fills in that spot with anything. For example, searching for urba* will search for: urban, urbane, urbanisation, urbanise, urbanism, urbanist, etc.

[a b c]

Square brackets tell vLex that the term within them is not strict, but an adjacent word within 30 degrees of separation. The main difference of using square brackets, as opposed to the asterisk, is that brackets will search for synonyms and expressions with semantic proximity, not just spelling. For example, if we wanted to include terms around transportation, we could search "urban planning" [train] AND Winnipeg. Using these terms, we get 8 results, and they include subway, tramway, and railway.

To restrict the words to less than 30 adjacent ones, you can add a / and a number to do it. For example, [transport]/5 will narrow the results to those where the terms are being discussed together.

Video walkthrough

Last updated