80 likes | 210 Views
In this exercise, we explore the concepts of functional dependency, attribute closure, and normalization in database design using a specific schema R = (A, B, C, G, H, I). We prove various functional dependencies and compute attribute closures to determine candidate keys. The exercise also covers lossless decomposition and whether specific decompositions preserve dependencies. We analyze Boyce-Codd Normal Form (BCNF) and Third Normal Form (3NF) to assess the normalization status of given relations. Finally, we find a minimal cover for a set of functional dependencies (FDs).
E N D
CSCI 4333 Database Design and Implementation – Exercise (3) Xiang Lian The University of Texas – Pan American Edinburg, TX 78539 lianx@utpa.edu
Functional Dependency • Given a schema R= (A, B, C, G, H, I) and a set of functional dependencies: F= {A B A C CG H CG I B H} • Please prove that the following functional dependencies are in F+: A H AG I CG HI
Attribute Closure • Given a schema R= (A, B, C, G, H, I)and a set of functional dependencies: F= { A B A C CG H CG I B H} • Please compute attribute closure (AG)+ • Is AG a candidate key?
Lossless Decomposition & Dependency Preserving • R = (A, B, C) F= {A B, B C} • Is the decomposition of R into R1= (A, B) and R2 = (B, C) lossless? Dependency preserving? • How about R1 = (A, B), R2 = (A, C)?
Boyce-Codd Normal Form (BCNF) • R = (A, B, C)F = {A B B C} • Is R in BCNF? Why? (Hint: Key = {A}) • How to decompose R if R is not in BCNF?
Third Normal Form (3NF) • R = (J, K, L)F = {JK L, L K} • Is R in 3NF? Why? (Hint: Two candidate keys: JK and JL)
Minimal Cover • Find a minimal cover of the following set of FDs: • ABCD • BCFG • AG • GB • CG • Is the decomposition of ABCDFG into ABCD and ACFG lossless? Explain.