FUNCTIONAL DEPENDENCY

Functional dependency is a relationship that exists when one attribute uniquely determines another attribute.
If R is a relation with attributes X and Y, a functional dependency between the attributes is represented as X → Y, which specifies Y is functionally dependent on X. Hear X is a determinant set and Y is dependent attribute. Each value of X is associated precisely with one Y value.

There are two type of functional dependencies :

• Partial Dependency
• Transitive Dependency

Partial Dependency - A partial dependency exists when there is a functional dependency in which the determinant is only part of the primary key (remember we are assuming there is only one candidate key).
For example - if (A,B) → (C,D), B → C, and (A,B) is the primary key, then the functional dependency B → C is a partial dependency because only part of the primary key (B) is needed to determine the value of C. Partial dependencies tend to be rather straight forward and easy to identify.

Example -
Student_Project(Student_id,Project_id, Project_name, Student_name)

Functional Dependency
(Student_id, Project_id) → (Project_Name, Student_name)

Partial Dependency
Project_id → Project_name
Student_id → Student_name

After Normalization the Student_Project table is divided into the following two tables :
Student(Student_id, Student_name, Project_id)
Project(Project_id, Project_name)

Transitive Dependency - A transitive dependency exists when there are functional dependencies such that X → Y, Y → Z and X is the primary key, in that case, the dependency X → Z is a transitive dependency because X determines the value of Z via Y. Unlike partial dependencies, transitive dependencies are more difficult to identify among a set of data. Fortunately, there is an easier way to identify transitive dependencies - A transitive dependency will occure only when a functional dependence exists among non-primary key attributes.

Example -

Functional Dependency

Transitive Dependency

After Normalization the Book_Details table is divided into the following two tables :
Book(Book_name, Author)

• In second normal form new tables are made to eliminate partial dependencies.
• In third normal form new tables are made to eliminate transitive dependencies.

QuestionSolves.com is an educational website that helps worldwide students in solving computer education related queries.

Also, different software like Visual Studio, SQL Server, Oracle etc. are available to download in different versions.

Moreover, QuestionSolves.com provides solutions to your questions and assignments also.

MORE TOPIC

WHAT WE DO

 Follow Us 