3NF - Example - Database

Q.  The functional dependencies for the relational schema student performance (name, courseNo, rollno, grade) is given below :

name, courseNo -> grade
rollno, courseNo -> grade
name -> rollno
rollno-> name

What is the highest normal form of this relational schema?

- Published on 25 Aug 15

a. 3NF
b. 4NF
c. BCNF
d. 2NF

ANSWER: 3NF
 

    Discussion

  • Nirja Shah   -Posted on 04 Nov 15
    - A technique of organising data is known as database Normalisation.

    - It is a systematic approach of decomposing tables to eliminate data redundancy and undesirable characteristics like Insertion, Update and Deletion Anamolies.

    - There is a multi-step process followed that puts data into tabular form by removing duplicated data from the relation tables.

    - It is mainly used for two purpose:
    1. Eliminating the redundant(useless) data.
    2. Ensuring data dependencies make sense i.e data is logically stored.

    2NF
    - In this form there must not be any partial dependency of any column on primary key.
    - It means that for a table that has concatenated primary key, each column in the table that is not part of the primary key must depend upon the entire concatenated key for its existence.
    - A table fails Second normal form when any column depends only on one part of the concatenated key.

    3NF
    - This form applies that every non-prime attribute of table must be dependent on primary key, or we can say that, there should not be the case that a non-prime attribute is determined by another non-prime attribute.
    - The transitive functional dependency should be removed from the table and also the table must be in Second Normal form.

    4NF
    - This normal form is used in database normalization.
    - It is the next level of normalization after Boyce–Codd normal form (BCNF).
    - Whereas the second, third, and Boyce–Codd normal forms are concerned with functional dependencies, 4NF is concerned with a more general type of dependency known as a multivalued dependency.
    - A Table is in 4NF if and only if, for every one of its non-trivial multivalued dependencies X \⇒ Y, X is a superkey—that is, X is either a candidate key or a superset thereof.

    BCNF
    - This normal form is a higher version of the third normal form.
    - It deals with certain type of anamoly that is not handled by 3NF.
    - A 3NF table which does not have multiple overlapping candidate keys is said to be in BCNF.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)