Zybook Week 5 Flashcards

1
Q

Normal Forms

A

Rules for designing tables with less redundancy.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Redundancy

A

Repetition of related values in a table. Causes database management problems.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Boyce-Codd Normal Form

A

Most important, improved version of third normal form

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Functional Dependence

A

Dependence of one column on another

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Mutlivalued dependence and join dependence

A

Entail dependencies between three or more columns. Complex, uncommon and primarily of theoretical interest.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

First Normal Form

A

When all non-key columns depend on the primary key.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Second Normal Form

A

When all non-key columns depend on the whole primary key aka a non-key column cannot depend on part of a composite primary key.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Third Normal Form

A

Redundancy can occur in a second normal form table when a non-key column depends on another non-key column. Informally, a table is in third normal form when all non-key columns depend on the key, the whole key, and nothing but the key.

Whenever a non-key column A depends on column B, then B is unique. Columns A and B may be simple or composite. Although B is unique, B is not necessarily minimal and therefore is not necessarily a candidate key.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Candidate Key

A

A candidate key is a simple or composite column that is unique and minimal. Minimal means all columns are necessary for uniqueness. A table may have several candidate keys. The database designer designates one candidate key as the primary key.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Non Key

A

A non-key column is a column that is not contained in a candidate key.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Boyce-Codd Nornmal Form

A

Boyce-Codd normal form if, whenever column A depends on column B, then B is unique. Columns A and B may be simple or composite. This definition is identical to the definition of third normal form with the term ‘non-key’ removed.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Trivial Dependencies

A

When the columns of A are a subset of the columns of B, A always depends on B. Ex: FareClass depends on (FlightCode, FareClass). These dependencies are called trivial.

Technically, trivial dependencies must be excluded in definitions of normal form: A table is in Boyce-Codd normal form if, for all non-trivial dependencies B → A, B is unique.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Normalization

A

eliminates redundancy by decomposing a table into two or more tables in higher normal form

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What are the steps to normalizing to Boyce-Codd normal form?

A

List all unique columns. Unique columns may be simple or composite. In composite columns, remove any columns that are not necessary for uniqueness. The primary key is unique and therefore always on this list.

Identify dependencies on non-unique columns. Non-unique columns are either external to all unique columns or contained within a composite unique column.

Eliminate dependencies on non-unique columns. If column A depends on a non-unique column B, A is removed from the original table. A new table is created containing A and B. B is a primary key in the new table and a foreign key in the original table.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Denormalization

A

means intentionally introducing redundancy by merging tables. Denormalization eliminates join queries and therefore improves query performance. Denormalization results in first and second normal form tables and should be applied selectively and cautiously.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly