DATA NORMALIZATION Flashcards

1
Q

What does A -> B mean?

A

A→ B is a functional dependency. This implies that A functionally determines B such that whenever two tuples agree on A they also agree on B.

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

What is a superkey?

A

A set of attributes that contains a key is called a superkey, short for ‘superset of a key’

A superkey satisfies the condition of a key: it functionally determines all other attributes of a relation, however; it need not satisfy the condition of minimality
(It just means that you remove one attribute/column from your key. If that reduced set of columns is still a key (i.e. uniquely identifies any data row), then the previous key was not minimal. )

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

Explain the splitting rule

A

If a key functionally determines more than one tuple:
A→ B,C,D
Then splitting the functional dependency is:
A→B A→C A→D

Note: A functional dependency cannot be split on the determinant (left side)

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

Explain the combining rule

A

Suppose:
A→B A→C A→D
Combining the functional dependency would result in:
A → B,C,D

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

Explain the transitive rule

A

Suppose A→B and B→C then A→C

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

What is a full functional dependency?

A

A functional dependency A → B is a full functional dependency if removal of any attribute from A results in the dependency no longer existing

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

What is a partial dependency?

A

A functional dependency A→B is a partial dependency if there is some attribute that can be removed from A and yet the dependency still holds.

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

What is data normalization?

A

Normalization is the process of splitting/decomposing relations into well structured relations that allow users to insert, delete, and update tuples without introducing database inconsistencies. These split up relations are then linked back together using foreign keys

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

What is the importance of data normalization

A

Ensures data integrity such that all integrity constraints are satisfied
Removes data redundancy by preventing anomalies
Brings about isolation of data
Prevents duplication of data

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

Explain an update anomaly

A

This occurs as a result of data redundancy (eg a record occurs more than once in a table) and partial update (not all of those records are updated) bringing about inconsistencies

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

Explain an insertion anomaly

A

An insertion anomaly is the inability to add data to the database due to the absence of other data.
For example, assume Student_Group is defined so that null values are not allowed. If a new employee is hired but not immediately assigned to a Student_Group then this employee could not be entered into the database.

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

Explain a deletion anomaly

A

A deletion anomaly exists when data belonging to certain attributes are lost because of the deletion of data belonging to other attributes in the same relation
For example, assume Student_Group is defined so that null values are not allowed. Then if the Student_Group of a certain employee is deleted the entire record of that employee will also be deleted.
(A delete anomaly is the opposite of an insert anomaly. When a delete anomaly occurs it means that you cannot delete data from the table without having to delete the entire record.)

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

What is unnormalized form?

A

A relation that contains one or more repeating groups( attributes with multiple values for a single occurrence) is said to be in Unnormalized form

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

Describe First normal form 1NF

A

A relation in which the intersection between each row and column contains only one value is said to be in 1NF. It has no composite attributes or repeating groups.

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

What are the two ways of moving from UF to 1NF?

A
  1. Flattening (Entering appropriate data in the empty attributes of tuples containing the
    repeating data) Ensures atomicity
    2.Placing the repeating data along with a copy of the original key attribute(s) in a separate relation
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

When is a relation said to be in 2nd Normal Form?

A

A relation that is in 1NF and every non- primary key attribute is fully, functionally dependent on the primary key is said to be in the second normal form

17
Q

What does normalization from 1NF to 2NF involve?

A

Removal of partial dependencies by removing the attributes that are partially dependent and placing them in a new relation along with a copy of their determinant

18
Q

When is a relation said to be in 3rd Normal Form?

A

A relation that is in 1NF and 2NF and in which no non-primary key attribute is transitively dependent on the primary key is said to be in the third normal form

19
Q

What does normalization from 2NF to 3NF involve?

A

Removal of transitively dependent attribute(s) from the relation by placing the attribute(s) in a new relation along with a copy of the determinant