4th and 5th Normal Form
Q.1: What is the difference between 4NF and 5NF in DBMS?
Answer:
A relation is in 5NF if it satisfies the properties of 4NF and has a lossless join and does not having any join dependency.
Q.2: What is the 6th Normal Form?
Answer:
Whenever the temporal data vary so much just for avoiding the undesired duplication, it is termed as 6th Normal Form.
Introduction of 4th and 5th Normal Form in DBMS
Two of the highest levels of database normalization are the fourth normal form (4NF) and the fifth normal form (5NF). Multivalued dependencies are handled by 4NF, whereas join dependencies are handled by 5NF.
If two or more independent relations are kept in a single relation or we can say multivalue dependency occurs when the presence of one or more rows in a table implies the presence of one or more other rows in that same table. Put another way, two attributes (or columns) in a table are independent of one another, but both depend on a third attribute. A multivalued dependency always requires at least three attributes because it consists of at least two attributes that are dependent on a third.
For a dependency A -> B, if for a single value of A, multiple values of B exist, then the table may have a multi-valued dependency. The table should have at least 3 attributes and B and C should be independent for A ->> B multivalued dependency.
Example:
Person | Mobile | Food_Likes |
---|---|---|
Mahesh | 9893/9424 | Burger/Pizza |
Ramesh | 9191 | Pizza |
Person->-> mobile,
Person ->-> food_likes
This is read as “person multi determines mobile” and “person multi determines food_likes.”
Note that a functional dependency is a special case of multivalued dependency. In a functional dependency X -> Y, every x determines exactly one y, never more than one.