Database Search Assignment

Bob_Usher
Database_Lab.pptx

What is the purpose of this Lab?

Know the terms and definitions used to describe databases and searches.

Understand how to get results from databases using:

Basic and Advanced searches.

Boolean Operators.

Wildcards.

1

Database terms and definitions:

What is a database?

A database is “a structured collection of records or data that is stored in a computer”.

Ex: Google maintains a giant database of webpages.

We will search for websites about vehicles using terms.

2

More definitions…

What is a search?

A search is the act of using keywords and/or keyphrases to find and return results from a database.

A search can contain keywords, keyphrases, boolean operators, and wildcards.

What are results?

Results are the collection of records returned.

In this lab, the results are a collection of links to webpages.

3

More definitions…

What is a term?

The keyword or keyphrase used to search a database.

What is a keyword?

The exact word you are looking for.

Here are some vehicle related keywords:

Vehicles, cars, trucks, automobiles

4

More definitions…

What is a keyphrase?

A keyphrase is the exact ordered group of keywords you are looking for.

A keyphrase MUST be in double-quotes:

“solar powered vehicle” is a keyphrase

solar powered vehicle is a list of keywords

Order matters in keyphrases

The following keyphrases have the same words but in different order. Each gives different results! Try it yourself:

Google Search: “solar powered vehicle”

is not the same as…

Google Search: “powered solar vehicle”

A strangely ordered keyphrase may not yield any results:

Google Search: “recipe grandma’s pie pumpkin”

Google will perform a second search without quotes. Why?

A list of keywords gives different results than the keyphrase:

These two searches give different results:

Google Search: solar powered vehicle

Google Search: “solar powered vehicle”

Notice that some of the results are the same while others are different. The results are also listed in a different order.

Why does this prove that the searches are not the same?

Using Boolean Operators for searching

What is a Boolean operator?

An operator that combines exactly two terms to get more or less results.

There are three Boolean operators: OR, AND, NOT.

8

Boolean operator examples

To get more results use OR

Search: car OR truck

Results:

Pages that ONLY have the term ‘car’

Pages that ONLY have the term ‘truck’,

Pages that have BOTH the term ‘car’ and ‘truck’.

To get less results use AND or NOT

Search: car AND truck

Results: Pages that have BOTH the term ‘car’ and ‘truck’.

Search: car NOT truck

Results: Pages that have the term ‘car’ but NOT the term ‘truck’.

Visualize Boolean searches with Venn Diagrams

Venn Diagrams are:

A set of partially overlapping circles.

Results are either inside or outside the circles.

10

Example of a Venn diagram

Using the OR Boolean Operator with the terms ‘car’, truck’, and ‘motorcycle.’

Notice that the OR operator returns more results the more it is used.

11

Another example of a Venn diagram

Using the AND Boolean Operator with the terms ‘car’, truck’, and ‘motorcycle.’

Notice that the AND operator returns fewer results the more it is used.

12

Wildcards

What is a wildcard?

A character that substitutes for one or more characters in a search.

Wildcards are often used when searching for a partial term that is found in multiple terms.

What are the wildcard characters?

They are different depending on the database but they are usually the asterisk(*) and the question mark(?):

Asterisk: *  Stands for 0 or more characters.

Question: ?  Stands for exactly 1 character.

13

Wildcard examples

Search: car*

Results include words with 0 or more substituted characters:

car

cars

cartoon

Search: car?

Results Include words with exactly 1 substituted character:

cars

cart

card

Advanced Search

What is an advanced search?

A search that gives you more options than just keywords and/or keyphrases.

Additional options in an advanced search include:

Language (i.e. English, French, etc.),

File Format (i.e. .htm, .pdf, etc.),

Location of keywords/phrases (i.e. title, URL, etc.)

And much more!