Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases...

39
Computer Technology LESSON 6: DATABASES AND WEB SEARCH ENGINES DEC. 1-5

Transcript of Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases...

Page 1: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Computer TechnologyLESSON 6:DATABASES AND WEB SEARCH ENGINES

DEC. 1-5

Page 2: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Monday

Page 3: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Overview of DatabasesA web search engine is a large database containing information about Web pages that have been registered with it.

To understand search engines, you must understand basic database concepts and the manner in which data is organized.

Page 4: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Overview of Databases

Database – an organized collection of information that pertains to a particular subject or purpose

Table – a collection of data about a specific topic, organized into columns and rows

Field – a category of information in a table (a column)

Record – a collection of information consisting of one or more related fields about a specific entity (a row)

Page 5: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational DatabasesA relational database contains multiple tables of information that are related through common fields.

By contrast, a non-relational database consists of multiple tables of information that are not related through common fields.

When multiple tables have a field in common, they can be joined to form a relationship to access the table data as needed.

Page 6: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational Databases

Relational database – a database that contains multiple tables related through common fields

Common field – a field, contained in two or more tables, that forms a relationship between the tables

Relationship – a connection between two or more tables based on a common field

◦ Relating tables eliminates the duplication of data

Page 7: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational DatabasesTo understand the relational database concept, consider a simple database designed for an aircraft manufacturer with three new aircrafts that will enter production soon.

The manufacturer wants to keep track of aircraft orders, as well as technical information about each aircraft.

Page 8: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

The Customers table contains information only about the aircraft ordered by each airline; it does not contain information about the aircraft.

The Aircraft Technical Specifications table contains information only about the aircraft.

The only field the two tables have in common is the Aircraft field; the tables are related through this common field.

Relating the two tables can save time and eliminate data duplication.

Page 9: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

PracticeIdentify the parts of the databases below

A

BC

Page 10: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Tuesday

Page 11: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Watch Databases and Web Search Engines clip

Page 12: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational DatabasesThe design of a relational database is usually determined by four factors:

1. The purpose of the database

2. The number of tables needed to store information without duplicating data

3. The fields needed in each table

4. The fields common to more than one table

Page 13: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational DatabasesA table relationship is established by matching data in key fields between two database tables.

In any given relationship, the table in which the common field is the primary key is called the primary table.

The other table in the relationship is called the related table. The common field in the related table is called the foreign key.

A database table can have only one primary key.

• Think about the example table:

– The Aircraft field is the primary key in the Aircraft Technical Specifications table because the information is unique.

Page 14: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relational Databases (cont’d)

Tables are related through their common fields

The common field is the primary key in one table and the foreign key in another table

◦ Primary key – a field containing a value that uniquely identifies each record in a table

◦ Foreign key – a field in a related table that refers to the primary key in another table

Page 15: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Primary key

Foreign key

Page 16: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database TablesThree types of relationships can be established between database tables:◦ One-to-one

◦ One-to-many

◦ Many-to-many

Page 17: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

One-to-many relationship – a record in Table A can have manymatching records in Table B, but a record in Table B has only onematching record in Table A (the most common table relationship)

A B

Page 18: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

One-to-one relationship – each record in Table A can have only one matching record in Table B

A B

Page 19: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

Many-to-many relationship –one record in either Table A or B can relate to many matching records in the other table

◦ Established by creating multiple one-to-many relationships with a third table (junction table)

A B

Page 20: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Wednesday

Page 21: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database TablesThree types of relationships can be established between database tables:◦ One-to-one

◦ One-to-many

◦ Many-to-many

Page 22: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

One-to-many relationship – a record in Table A can have manymatching records in Table B, but a record in Table B has only onematching record in Table A (the most common table relationship)

A B

Page 23: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

One-to-one relationship – each record in Table A can have only one matching record in Table B

A B

Page 24: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Relating Database Tables

Many-to-many relationship –one record in either Table A or B can relate to many matching records in the other table

◦ Established by creating multiple one-to-many relationships with a third table (junction table)

A B

Page 25: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject
Page 26: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Thursday

Page 27: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

ClassworkIn your groups draw an 3 examples of your database relationship

A. One-to-one

B. One-to-many

C. Many-to-many

Page 28: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Querying Databases Using SQLUsers input queries to selectively view and analyze data from a database.

A query isolates and displays only the information you want to examine by specifying the fields and records you want to see.◦ For example, you can use a query to display only the cruising speed, range and capacity of the aircraft

that TransCon ordered.

Page 29: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Querying Databases Using SQL

There are three general types of queries:

◦ Menu query — You are offered a list of options in a menu from which to choose.

◦ Query by example — You specify the fields and data values to be used in a query.

◦ Query language — You use a specialized language called Structured Query Language (SQL) to retrieve and manipulate information in a database.

Structured Query Language (SQL) – the standard interactive and programming language for accessing information from and updating information in relational databases

Page 30: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Common Database VendorsA database management system (DBMS) is a program used to store, access and manipulate database information.

IT professionals commonly use a DBMS to work with corporate database information.

Common database vendors and their DBMS products (in parentheses) include the following:◦ IBM (DB2)

◦ Computer Associates (Advantage)

◦ Oracle (Oracle Database)

◦ Microsoft (SQL Server, Microsoft Access)

Page 31: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Introduction to Web Search Engines

Search engine – a powerful software program that makes it easy to find information on the Internet

◦ Use keywords to find information about any subject you want to investigate

◦ Many engines use "robots" or "spiders" to automatically search the Web and index Web sites

Page 32: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Registering a Web Site with a Search Engine

Many popular search engines require that you register your Web site for it to be accessible to Web users. Each search engine has its own registration process.

Page 33: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Friday

Page 34: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Registering a Web Site with a Search Engine

Add your Web site to search engines to make it available to Web users

1. Register your site by completing an online form and entering the URL of your site

2. Robots search your site for relevant keywords found in the <meta> tag

3. Search engines that scan Web pages for <meta> tags are called meta search engines

Page 35: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

The <meta> TagThe <meta> tag is an HTML element used in a Web page to embed information for use by search engines.

This information is placed near the top of the HTML document so search engines can quickly access it.

The more descriptive the information included in the <meta> tag, the more likely the Web site is to rank high in search results.

The <meta> tag includes information about a document, such as:◦ Keywords to be used by some search engines.

◦ A description of the site's content for display in some search engines.

◦ An expiration date for the document.

◦ The document's author.

Page 36: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Search Engines vs.Information Portals

The term search engine is used loosely to refer to search engines and information portals

◦ Search engine – uses a robot or spider program to browse the Web following hyperlinks, and index the content that it finds

◦ Information portal – only finds Web sites based on manual submissions

Information portals are more likely to contain high-quality content matches to any given query

Page 37: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

Search Engines vs.Information Portals

YAHOO-INFORMATION PORTAL GOOGLE-SEARCH ENGINE

Information organized like the a directory.

Google only allows users to conduct searches

Page 38: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

HomeworkGive 2 examples of a search engine

Give 2 examples of an information portal

Page 39: Computer Technologymshallsouthcreekms.weebly.com/uploads/2/2/2/6/... · Overview of Databases Database –an organized collection of information that pertains to a particular subject

ClassworkObjective 1.16 Review and Quiz