Google Logic5.1 Search Box Boolean
Now that you are familiar with the many alternatives and controls you can impose on a search by using the Advanced Search Page discussed in the previous chapter, you'll be happy to hear that you can perform the same kinds of searches right in Google's regular search box by using any of a number of command operators. In this chapter we will look at the logical operators related to Boolean logic, and in the next chapter we'll look at the advanced operators that Google supports. You'll learn how to be a power user who can build specific, custom queries on the fly.
Remember that by default, Google understands all multiple word queries in terms of Boolean AND commands:
frosted strawberry shortcake
is parsed as
frosted AND strawberry AND shortcake
. Additionally, Google parses the query with an implied preference for proximity. That is, when you type in more than one search term, Google will return all pages with those terms anywhere on them, but it will rank higher those pages where the terms occur closer together. This is the equivalent of specifying a NEAR command as a preference rather than a requirement. The advantage of this preference for proximity over a command such as
strawberry NEAR shortcake
is that not only will you get pages with strawberry near shortcake but eventually you'll also see pages with
rather far from
Tip 5.1 Quick Biography
If you need biographical information about a well-known person, you can visit a site such as Biography.com
) to see a brief entry. Or you can use Google. The words "was born" will key you into biographical information. Try some of these queries or model your own after them and see what you get:
5.2 Restricting the Search
"Samuel Johnson was born"
"Anwar Sadat was born"
"Anne Bradstreet was born"
"Golda Meir was born"
As you already know, you can restrict your search simply by adding more search words to your query. The more terms that Google must match, the fewer matches there are likely to be. You can also use some logical operators to restrict your search.
The plus sign (+) that we discussed earlier can be used in the regular Google search box to tell Google that the term following the sign must be included on the pages returned, even when the term is a stop word. The only rule for using this operator is that there must be a space before it but not between it and the word it controls:
easy +to make candles
, none between + and
). In this particular search expression, you could have specified an exact phrase search
"easy to make candles"
, but then you would have missed pages that used the phrase
how to make candles
that also contained the word
. That said, in practical terms, it's usually easier to specify an exact phrase search by using quotation marks if an exact phrase is what you want.
Must not include.
Google's operator that performs the Boolean NOT function is the minus sign (-). Just as with the plus sign, it is put it next to a word (space before the sign but not after). This operator tells Google to skip every page that contains the rejected word. For example, searching for
"aircraft fly in"
(with the quotation marks) yields about 1400 hits. Including the rejection of
to prevent pages that refer to model aircraft reduces the number of hits:
"aircraft fly in" -model
returns under 1000.
Caution is again advised with the use of the NOT operator (the minus sign). In the example here, any page that referred to model airplanes would be rejected, but so would pages referring to regular aircraft fly ins if they also mentioned that some aircraft served as a model for another, or that fashion models would show off flying suits during the show. If you're searching for, say, malic acid and know you don't want to read about its uses in candy, feel free to use
malic acid -candy
as your search phrase. But think about the consequences of the word you plan to use as a page rejection.
As mentioned, quotation marks create an exact phrase search, telling Google to look for those words, in that order, including stop words. A long enough exact phrase will restrict the number of hits you get dramatically. In fact, if you look for an unusual enough phrase, you can reduce the number of hits to just a handful and sometimes even to one. For the value of such a search, see the tip below.Tip 5.2 Finding Lost Pages
Suppose you have included a paragraph from a Web article in your research paper and you suddenly discover that you have lost the source. Clumsily, your roommate has erased the saved HTML file, your dog ate the Web printout, and there is now no record of where you got it. If you find a four-to-six word string of words that creates an unusual phrase, you can perform an exact phrase search for those words using Google and find the page again. An easy way to find such a unique phrase is to include a couple of words before and a couple of words after the end of a sentence. For example, to find this paragraph online, you could search on "lost the source clumsily your roommate" and find it in a Google wink. This technique of searching across punctuation almost always brings up the source in the first or second hit.5.3 Expanding the Search
To include alternative words and to expand the number of pages in your results, you have two options.
This operator tells Google to include all pages containing either word (not both) on each side of the operator. Use OR to include
alternative forms of the same word. For example,
gold plated OR plating
synonyms or alternative expressions. For example,
radiometric dating OR geochronolgy
millennium OR milennium OR millenium
alternative spellings. For example,
insurance payor OR payer, spacetime OR "space time"
American and British spellings. For example,
dead pan humor OR humour
Remember that if you simply list alternative forms of a word, Google will interpret your request as an AND query and attempt to find pages with every one of the words you type in. So, if you mean this OR that, be sure to specify. Important note: For once, capitalization does matter.
Be sure to capitalize the OR in your search expression or Google will ignore it as a stop word.
Tip 5.3 What Does It Do?Imagine that you are reading the label of a shampoo bottle and you notice that one of the ingredients is methylparaben. You wonder what benefits that has for your hair. Because that is such an unusual word, you try a single word search and type
into the Google search window. You note that there are 50,000 results. You might also try typing in
, for 7,000 results, but what you really want to know is what the ingredient does. For a quick result, do an exact phrase search that includes the words
. Here are some examples to try or to model your own queries after:
Your second choice for including alternative words is to include the wildcard in an exact phrase search. The wildcard for Google is the asterisk (*). Google does not support stemming (or truncation) so you cannot use it to match pieces of a word, as in
sculpture, sculpt, sculpting
and so forth. Google's wildcard tells the engine to "accept any word here." For example, the search
"run * the mill"
will return pages with
run of the mill
run in the mill
run at the mill
, and so on. If you are unsure of the word in a title, you can use the wildcard to stand for every possibility. For an example, type
"federal * of corrections"
into the Google search box.
"methylparaben is used"
"luminol is used"
"Kevlar is used"
"polychlorinated biphenyls were used"
Tip 5.4 Try BothWhen building your search queries, if you have what may or may not be an exact phrase, enter it both as a phrase search with the quotation marks and then as a string of search words without the quotation marks. For example, if you are researching the danger of window blinds to children, search on both
"window blind safety"
window blind safety
. You'll get pages that use that phrase and pages that include the words but not in the exact phrase. In each case, the order of the pages will be somewhat different, possibly giving you a helpful insight into the subject.
5.4 Refining the Search
Often the best strategy to pursue with a search is to see it as an iterative process, where you search on some relevant terms, see what you get, and then refine your search over and over to get exactly what you want. Here are some ideas to help you.
Change words as needed.
Begin your search with just a few words. When you see your results, change one or more of the words to focus your search more clearly on what you want.
Include OR alternatives to be sure to get variants.
Remember that some pages may use
. If you're not seeing the kind or number of pages you expect, try adding some alternative terms.
Add words to focus.
If your results still appear to be not as tightly focused as you want, add more words to restrict your results to a narrower subject area. Remember this will also reduce the number of your results.
Exclude unwanted pages.
Use the minus sign. If you notice many pages that include your search terms but that discuss some other topic, see what the unwanted pages have in common and use the
must not include
operator (-) to eliminate them. For example
celtic songs -irish -ireland
Choose similar pages.
On the Google results page click on the "Similar pages" hyperlink next to a page you find useful.
Search in the results.
Go to the bottom of the results page and click on "Search within results" to narrow down your results. For example, searching on
yielded 140,000 results. Choosing "Search within results" and adding
narrowed the results down to 1600. Note that you could have performed the same refinement by simply adding the word in the regular search box, creating the query
barking problem chihuahua
Tip 5.5 Copy and Paste Printing
Some Web pages are very hostile to printing. Black pages with white or yellow type are especially problematic and may print out either as blank pages (on a laser printer) or (on a color ink jet printer) in glorious ink-cartridge-killing black with white type. Even some pages in frames or with wide borders create headaches by producing printed pages with text cut off on the right. The solution to these issues is to copy and paste. Highlight the text you want to print, copy it (with Edit, Copy or Control-C) and then paste it into a word processor (Word, Wordpad, Notepad, anything you've got) with Edit, Paste or Control-V. From there you can do a bit of formatting. Be sure to copy and paste the full URL of the page into the document before you print it out so you will remember where you got it.
Copyright ©2003 by McGraw-Hill/Dushkin, Guilford, CT 06437,
A Division of The McGraw-Hill Companies.
Copyright law prohibits the reproduction, storage, or transmission in any form by any means of any portion of this publication without the express written permission of Dushkin/McGraw-Hill, and of the copyright holder (if different) of the part of the publication to be reproduced. The Guidelines for Classroom Copying endorsed by Congress explicitly state that unauthorized copying may not be used to create, to replace, or to substitute for anthologies, compilations, or collective works.