Chapter 11 Functional Dependencies. Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-2 Topics in this Chapter Basic Definitions Trivial.

Slides:



Advertisements
Similar presentations
Functional dependencies 1. 2 Outline motivation: update anomalies cause: not expressed constraints on data (FDs) functional dependencies (FDs) definitions.
Advertisements

1 Term 2, 2004, Lecture 2, Normalisation - IntroductionMarian Ursu, Department of Computing, Goldsmiths College Normalisation Introduction.
Dr. Alexandra I. Cristea CS 319: Theory of Databases.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 16 Relational Database Design Algorithms and Further Dependencies.
Manipulating Functional Dependencies Zaki Malik September 30, 2008.
Temple University – CIS Dept. CIS616– Principles of Data Management V. Megalooikonomou Functional Dependencies (based on notes by Silberchatz,Korth, and.
Database Management COP4540, SCS, FIU Functional Dependencies (Chapter 14)
Properties of Armstrong’s Axioms Soundness All dependencies generated by the Axioms are correct Completeness Repeatedly applying these rules can generate.
CMU SCS Carnegie Mellon Univ. Dept. of Computer Science /615 - DB Applications Lecture #16: Schema Refinement & Normalization - Functional Dependencies.
The Relational Model System Development Life Cycle Normalisation
Normalization DB Tuning CS186 Final Review Session.
Multivalued Dependency Prepared by Tomasz Kaciak CS157A.
CMSC424: Database Design Instructor: Amol Deshpande
DATABASE DESIGN Functional Dependencies. Overview n Functional Dependencies n Normalization –Functional dependencies –Normal forms.
Functional Dependencies (Part 3) Presented by Nash Raghavan All page numbers are in reference to Database System Concepts (5 th Edition)
1 CMSC424, Spring 2005 CMSC424: Database Design Lecture 9.
Normalization. FarkasCSCE 5202 Reading Assignments  Database Systems The Complete Book: Chapters 3.6, 3.7, 3.8  Following lecture slides are modified.
Fall 2001Arthur Keller – CS 1804–1 Schedule Today Oct. 4 (TH) Functional Dependencies and Normalization. u Read Sections Project Part 1 due. Oct.
Chapter 14 Advanced Normalization Transparencies © Pearson Education Limited 1995, 2005.
Chapter 8: Relational Database Design First Normal Form First Normal Form Functional Dependencies Functional Dependencies Decomposition Decomposition Boyce-Codd.
©Silberschatz, Korth and Sudarshan7.1Database System Concepts Chapter 7: Relational Database Design First Normal Form Pitfalls in Relational Database Design.
Functional Dependencies Prof. Yin-Fu Huang CSIE, NYUST Chapter 11.
Chapter 5 Integrity Constraints 5.1 Domain ConstraintsDomain Constraints 5.2 Referential IntegrityReferential Integrity 5.3 AssertionsAssertions 5.4 TriggersTriggers.
FUNCTIONAL DEPENDENCIES
Chapter 7: Relational Database Design. 7.2Unite International CollegeDatabase Management Systems Chapter 7: Relational Database Design Features of Good.
Chapter 13 Further Normalization II: Higher Normal Forms.
Lecture 6 Normalization: Advanced forms. Objectives How inference rules can identify a set of all functional dependencies for a relation. How Inference.
Design Theory for Relational Databases 2015, Fall Pusan National University Ki-Joune Li.
CSC271 Database Systems Lecture # 28.
THIRD NORMAL FORM (3NF) A relation R is in BCNF if whenever a FD XA holds in R, one of the following statements is true: XA is a trivial FD, or X is.
BCNF & Lossless Decomposition Prof. Sin-Min Lee Department of Computer Science.
Normalization Ioan Despi 2 The basic objective of logical modeling: to develop a “good” description of the data, its relationships and its constraints.
CS 564 Database Management Systems: Design and Implementation Discussion Session Friday, Sept 18, Apul Jain.
Logical Database Design (1 of 3) John Ortiz Lecture 6Logical Database Design (1)2 Introduction  The logical design is a process of refining DB schema.
Functional Dependencies. FarkasCSCE 5202 Reading and Exercises Database Systems- The Complete Book: Chapter 3.1, 3.2, 3.3., 3.4 Following lecture slides.
1 Dept. of CIS, Temple Univ. CIS616/661 – Principles of Data Management V. Megalooikonomou Integrity Constraints (based on slides by C. Faloutsos at CMU)
Minimum Cover of F. Minimal Cover for a Set of FDs Minimal cover G for a set of FDs F: –Closure of F = closure of G. –Right hand side of each FD in G.
Lecture No 13 Functional Dependencies & Normalization ( II ) Mar 3 rd 2011 Database Systems.
Rensselaer Polytechnic Institute CSCI-4380 – Database Systems David Goldschmidt, Ph.D.
CMU SCS Carnegie Mellon Univ. Dept. of Computer Science /615 - DB Applications Lecture #16: Schema Refinement & Normalization - Functional Dependencies.
Chapter 5.1 and 5.2 Brian Cobarrubia Database Management Systems II January 31, 2008.
Schema Refinement and Normalization Nobody realizes that some people expend tremendous energy merely to be normal. Albert Camus.
Databases Illuminated
Functional Dependencies CIS 4301 Lecture Notes Lecture 8 - 2/7/2006.
Rensselaer Polytechnic Institute CSCI-4380 – Database Systems David Goldschmidt, Ph.D.
MIS 3053 Database Design And Applications The University Of Tulsa Professor: Akhilesh Bajaj Normal Forms Lecture 1 © Akhilesh Bajaj, 2000, 2002, 2003.
CS 222 Database Management System Spring Lecture 4 Database Design Theory Korra Sathya Babu Department of Computer Science NIT Rourkela.
CS542 1 Schema Refinement Chapter 19 (part 1) Functional Dependencies.
Databases 1 Sixth lecture. 2 Functional Dependencies X -> A is an assertion about a relation R that whenever two tuples of R agree on all the attributes.
© D. Wong Functional Dependencies (FD)  Given: relation schema R(A1, …, An), and X and Y be subsets of (A1, … An). FD : X  Y means X functionally.
Chapter 8 Relational Database Design. 2 Relational Database Design: Goals n Reduce data redundancy (undesirable replication of data values) n Minimize.
1 CS 430 Database Theory Winter 2005 Lecture 8: Functional Dependencies Second, Third, and Boyce-Codd Normal Forms.
Normalization and FUNctional Dependencies. Redundancy: root of several problems with relational schemas: –redundant storage, insert/delete/update anomalies.
Advanced Normalization
CS422 Principles of Database Systems Normalization
CS422 Principles of Database Systems Normalization
Advanced Normalization
Chapter 17 Linked Lists.
Chapter 19 Binary Search Trees.
Chapter 4 Inheritance.
Chapter 14 Graphs and Paths.
Database Normalization
Chapter 10 Datapath Subsystems.
Chapter 20 Hash Tables.
Functional Dependencies
Minggu 9, Pertemuan 18 Normalization
The Facts to Be Explained
Circuit Characterization and Performance Estimation
Chapter 2 Reference Types.
Presentation transcript:

Chapter 11 Functional Dependencies

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-2 Topics in this Chapter Basic Definitions Trivial and Nontrivial Dependencies Closure of a Set of Dependencies Closure of a Set of Attributes Irreducible Sets of Dependencies

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-3 Functional Dependence Functional dependence is a many to one relationship from one set of attributes to another within a given relvar Let r be a relation, and let X and Y be subsets of the attributes of r X  Y says “Y is functionally dependent on X”, or “X functionally determines Y” X is the determinant; Y the dependent

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-4 Trivial and Nontrivial Dependencies An FD is trivial if and only if the right side is a subset of the left side { S#, P# }  S# All other dependencies are called nontrivial

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-5 Closure of a Set of Dependencies The set of all FDs that are implied by a given set S of FDs is called the closure of S Armstrong’s axioms (see next slide) are used to infer FDs from others Let A, B, and C be subsets of relvar R, and let AB signify the union of A and B

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-6 Closure of a Set of Dependencies – Armstrong’s Axioms Reflexivity: If B is a subset of A the A  B Augmentation: If A  B, then AC  BC Transitivity:If A  B and B  C, then A  C Self-determination: A  A Decomposition: If A  BC, then A  B and A  C Union: If A  B and A  C, then A  BC Composition: If A  B and C  D, then AC  BD

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-7 Closure of a Set of Attributes The set of all attributes that are implied by a given set of attributes S is called the closure of S A superkey implies all the other attributes of a relvar The nonkey attributes of a relvar represent a closure of the superkey, but not necessarily an irreducible one Any group of attributes for which all the other attributes represent a closure is a superkey

Copyright © 2004 Pearson Addison-Wesley. All rights reserved.11-8 Irreducible Sets of Dependencies Let S1 and S2 be two sets of FDs. If every FD implied by S1 is implied by S2, then S2 is a cover of S1 A set S of FDs is irreducible iff: The right side of every FD in S involves one attribute (a singleton set) The left side is irreducible No FD in S can be discarded without changing the closure of S