Find the canonical cover of FD {A->BC, B->AC, C->AB} in DBMS


Canonical cover is called minimal cover which is called the minimum set of FDs. A set of FD FC is called canonical cover of F if each FD in FC is a Simple FD, Left reduced FD and Non-redundant FD.

Simple FD − X->Y is a simple FD if Y is a single attribute.

Left reduced FD: X->Y is a left reduced FD if there are no extraneous attributes in X.{extraneous attributes: let XA->Y then A is a extraneous attribute if X_>Y}

Non-redundant FD − X->Y is a Non-redundant FD if it cannot be derived from F- {X->y}.

Problem

Find the canonical cover of FD {A->BC, B->AC, C->AB}.

Solution

Relational schema R(A,B,C) F: {A->BC, B->AC, C->AB}

Step 1 − Create a singleton right hand side

dependency A->BC will break into A->B, A->C.

F: { A->B
    A->C
    B->A
    B->C
    C->A
    C->B}

Step 2 − Remove extraneous attributes if any exists.

F:{ A->B
   A->C
   B->A
   B->C
   C->A
   C->B}  NO extraneous attributes exists

Step 3 − Remove the redundant FD

F: { A->B
    A->C
    B->A
    B->C
    C->A
    C->B }

Remove B->A dependency and we can get A from B through B->C and C->A.

F= {A->B
   A->C
   B->C
   C->A
   C->B}

By removing C->B dependency we get B from C through C->A , A->B.

F={A->B
   B->C
   C->A
   A->C}

By removing A->C dependency we can determine C from A through A->B, B->C

Step 4 − The final canonical cover is as follows −

FC ={ A->B, B->C, C->A }
[A]+ =BC
[B]+=AC
[C]+=AB.

Updated on: 03-Jul-2021

7K+ Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements