Technology in terms you understand. Sign up for the Confident Computing newsletter for weekly solutions to make your life easier. Click here and get The Ask Leo! Guide to Staying Safe on the Internet — FREE Edition as my thank you for subscribing!

How do I exclude irrelevant yet matching pages from a search?

Question:

An old friend has the same name as a famous person, so when I try to find
anything about her the results are 10,000 hits on the famous one. Is there any
way to search for people with except “movie star” or something?

In this excerpt from
Answercast #52
, I look at ways to exclude search terms when searching the
web for information.

Become a Patron of Ask Leo! and go ad-free!

Exclude words from a search

Well, first of all it really depends on where you’re doing your search.
Different search engines have different approaches to their ability to specify
what are referred to as “negative matches.”

Now, “except movie star” doesn’t really make sense. I mean – “movie star” is
a very, vague term. There’s no real rock solid definition. Computers need
things to be very, very specific. By being specific, what I mean is that:

  • You need to specify criteria that either match or don’t match.

  • Words that either match or don’t match.

And by words I mean literally the words that you’re expecting or
wanting to exclude from the web pages that you visit.

Negative matches on Google

On Google, you can use the minus sign. So, you could, for example, search
for “Leo” and there would be a bunch of Leos. Most of them aren’t me.

You could search for “Leo -ask” (so Leo, space, a minus sign in front of the
word “ask”.) That will return all pages that have the word “Leo” and don’t have
the word “Ask”. So you would not, for example, find Ask Leo!. Hopefully, in
that first one you would.

You could, of course, search for “Ask Leo!” and Ask Leo! will come up first.
But if you just put a minus sign in front of the word “Ask” then all of a
sudden pages that have the word “Ask” are excluded from the results.

Finding the right terms

Now, what does this mean for your movie star problem? Well, I’m not really
sure. It kind of depends on the specifics of the movie star that you keep
seeing.

You can’t just say -“movie star” because the word “movie star” may not
appear on all of those pages that are in fact, about that movie star. So what
you need to do is take a look at the kind of pages that are coming up for that
movie star and identify a couple of words that are on all of those
pages – but then are not on the pages for the friend that you’re looking
for.

So you might see perhaps, that a movie star is known for a specific movie,
right? Maybe the movie star starred in a movie called “Colossus”. So what you
might do is you search for the name of your friend and then include
-Colossus.

That way all of the pages about this movie star that happen to mention this
movie star’s movie, “Colossus” would automatically be excluded. You can have
multiple minuses so if there’s a handful of movies, you could specify specific
titles or specific words from those movies. That would cause those pages to get
excluded.

Google “minus” syntax

Google actually has a fairly robust search phrase syntax with lots of
different options. Minus is a very interesting one that I recommend you look
into for exactly this kind of a problem.

It will take a little bit of work because, like I said, you can’t remove a
concept like “movie star’. You have to remove specific words that are appearing
on web pages. But once you get the hang of that, it
may very well help you refine your search – and actually find the pages talking
about your friend and not this movie star.

Do this

Subscribe to Confident Computing! Less frustration and more confidence, solutions, answers, and tips in your inbox every week.

I'll see you there!

Leave a reply:

Before commenting please:

  • Read the article.
  • Comment on the article.
  • No personal information.
  • No spam.

Comments violating those rules will be removed. Comments that don't add value will be removed, including off-topic or content-free comments, or comments that look even a little bit like spam. All comments containing links and certain keywords will be moderated before publication.

I want comments to be valuable for everyone, including those who come later and take the time to read.