• Shuffle
    Toggle On
    Toggle Off
  • Alphabetize
    Toggle On
    Toggle Off
  • Front First
    Toggle On
    Toggle Off
  • Both Sides
    Toggle On
    Toggle Off
  • Read
    Toggle On
    Toggle Off
Reading...
Front

Card Range To Study

through

image

Play button

image

Play button

image

Progress

1/17

Click to flip

Use LEFT and RIGHT arrow keys to navigate between flashcards;

Use UP and DOWN arrow keys to flip the card;

H to show hint;

A reads text to speech;

17 Cards in this Set

  • Front
  • Back

What is database normalization?

A set of rules for organizing attributes & tables

What are three reasons for database normalization?

Eliminates anomalies, minimizes redundancy, and improves database performance

What does first normal form require?

All fields only include a single piece of data.

How is first normal form corrected?

By adding a table with a one-to-many relationship

What does second normal form require?

All non-key fields must be functionally dependent on every part of a composite primary key

What does third normal form require?

All non-key fields are not functionally dependent on another non-key field.

What is denormalization?

Knowingly violating a normalization form.

What are indexes?

A copy of a column of data from a table that can be searched more efficiently.

Why use an index?

Searching non-key values is slow, indexes speed up retrieval.

What are downsides to an index?

Slows down updates, adds redundant data to a database, and increases the size.

Candidates for an index?

Non-key fields that you need to search regularly, fields that change infrequently, and shorter fields.

What is a view?

A "window" into a portion of the database (virtual table).

Why use a view?

Maintain confidentiality by restricting access to certain parts of the database, and simplify frequently used queries.

Limitations of a view?

No parameters, no sub-queries, and no table/data modifications.

What is a stored procedure?

A set of SQL statements with an assigned name. Stored in the database in compiled form and can be shared by a number of applications.

Why use a stored procedure?

Easy to maintain, faster than queries (pre-cached), and more secure.

Difference between views and stored procedures?

Views are single, read-only select statements while stored procedures can be CRUD statements, multiple statements, parameters, and programming logic.