Prerequisite: Functional dependency and attribute closure Show A functional dependency is a constraint that specifies the relationship between two sets of attributes where one set can accurately determine the value of other sets. It is denoted as X → Y, where X is a set of attributes that is capable of determining the value of Y. The attribute set on the left side of the arrow, X is called Determinant, while on the right side, Y is called the Dependent. Functional dependencies are used to mathematically express relations among database entities and are very important to understand advanced concepts in Relational Database System and understanding problems in competitive exams like Gate. Example:
From the above table we can conclude some valid functional dependencies:
Here are some invalid functional dependencies:
Armstrong’s axioms/properties of functional dependencies:
Types of Functional dependencies in DBMS:
1. Trivial Functional DependencyIn Trivial Functional Dependency, a dependent is always a subset of the
determinant. For example,
Here, {roll_no, name} → name is a trivial functional dependency, since the dependent name is a subset of determinant set {roll_no, name} 2. Non-trivial Functional DependencyIn Non-trivial functional dependency, the dependent is strictly not a subset of the
determinant. For example,
Here, roll_no → name is a non-trivial functional dependency, since the dependent name is not a subset of determinant roll_no 3. Multivalued Functional DependencyIn Multivalued
functional dependency, entities of the dependent set are not dependent on each other. For example,
Here, roll_no → {name, age} is a multivalued functional dependency, since the dependents name & age are not dependent on each other(i.e. name → age or age → name doesn’t exist !) 4. Transitive Functional DependencyIn transitive functional dependency, dependent is indirectly dependent on determinant. For example,
Here, enrol_no → dept and dept → building_no, What is the meaning of functionally dependent?Functional dependency is a relationship that exists when one attribute uniquely determines another attribute.
What does it mean for a column to be functionally dependent on another column?Definition: A column is functionally dependent on another column if a value 'A' determines a single value for 'B' at any one time.
What is functional dependency explain with an example?For example:
Assume we have an employee table with attributes: Emp_Id, Emp_Name, Emp_Address. Here Emp_Id attribute can uniquely identify the Emp_Name attribute of employee table because if we know the Emp_Id, we can tell that employee name associated with it. Functional dependency can be written as: Emp_Id → Emp_Name.
What is a dependent attribute in database?An attribute is fully functional dependent on another attribute, if it is Functionally Dependent on that attribute and not on any of its proper subset. For example, an attribute Q is fully functional dependent on another attribute P, if it is Functionally Dependent on P and not on any of the proper subset of P.
|