Database Design and Relational Theory

Book description

What makes this book different from others on database design? Many resources on design practice do little to explain the underlying theory, and books on design theory are aimed primarily at theoreticians. In this book, renowned expert Chris Date bridges the gap by introducing design theory in ways practitioners can understand—drawing on lessons learned over four decades of experience to demonstrate why proper database design is so critical in the first place.

Every chapter includes a set of exercises that show how to apply the theoretical ideas in practice, provide additional information, or ask you to prove some simple theoretical result. If you’re a database professional familiar with the relational model, and have more than a passing interest in database design, this book is for you.

Questions this book answers include:

  • Why is Heath’s Theorem so important?
  • What is The Principle of Orthogonal Design?
  • What makes some JDs reducible and others irreducible?
  • Why does dependency preservation matter?
  • Should data redundancy always be avoided? Can it be?

Databases often stay in production for decades, and careful design is critical for avoiding subtle errors and processing problems over time. If they’re badly designed, the negative impacts can be incredibly widespread. This gentle introduction shows you how to use important theoretical results to create good database designs.

Publisher resources

View/Submit Errata

Table of contents

  1. Database Design and Relational Theory
  2. Dedication
  3. Preface
      1. Prerequisites
      2. Logical vs. Physical Design
      3. Acknowledgments
  4. I. SETTING THE SCENE
    1. 1. Preliminaries
      1. SOME QUOTES FROM THE LITERATURE
      2. A NOTE ON TERMINOLOGY
      3. THE RUNNING EXAMPLE
      4. KEYS
      5. THE PLACE OF DESIGN THEORY
      6. AIMS OF THIS BOOK
      7. CONCLUDING REMARKS
      8. EXERCISES
    2. 2. Prerequisites
      1. OVERVIEW
      2. RELATIONS AND RELVARS
      3. PREDICATES AND PROPOSITIONS
      4. MORE ON SUPPLIERS AND PARTS
      5. EXERCISES
  5. II. FUNCTIONAL DEPENDENCIES, BOYCE/CODD NORMAL FORM, AND RELATED MATTERS
    1. 3. Normalization: Some Generalities
      1. NORMALIZATION SERVES TWO PURPOSES
      2. UPDATE ANOMALIES
      3. THE NORMAL FORM HIERARCHY
      4. NORMALIZATION AND CONSTRAINTS
      5. CONCLUDING REMARKS
      6. EXERCISES
    2. 4. FDs and BCNF (Informal)
      1. FIRST NORMAL FORM
      2. FUNCTIONAL DEPENDENCIES
      3. KEYS REVISITED
      4. SECOND NORMAL FORM
      5. THIRD NORMAL FORM
      6. BOYCE/CODD NORMAL FORM
      7. EXERCISES
    3. 5. FDs and BCNF (Formal)
      1. PRELIMINARY DEFINITIONS
      2. FUNCTIONAL DEPENDENCIES
      3. BOYCE/CODD NORMAL FORM
      4. HEATH’S THEOREM
      5. EXERCISES
    4. 6. Preserving FDs
      1. AN UNFORTUNATE CONFLICT
      2. ANOTHER EXAMPLE
      3. ... AND ANOTHER
      4. ... AND STILL ANOTHER
      5. A PROCEDURE THAT WORKS
      6. IDENTITY DECOMPOSITIONS
      7. MORE ON THE CONFLICT
      8. INDEPENDENT PROJECTIONS
      9. EXERCISES
    5. 7. FD Axiomatization
      1. ARMSTRONG’S AXIOMS
      2. ADDITIONAL RULES
      3. PROVING THE ADDITIONAL RULES
      4. ANOTHER KIND OF CLOSURE
      5. EXERCISES
    6. 8. Denormalization
      1. “DENORMALIZE FOR PERFORMANCE”?
      2. WHAT DOES DENORMALIZATION MEAN?
      3. WHAT DENORMALIZATION ISN’T (I)
      4. WHAT DENORMALIZATION ISN’T (II)
      5. DENORMALIZATION CONSIDERED HARMFUL (I)
      6. DENORMALIZATION CONSIDERED HARMFUL (II)
      7. A FINAL REMARK
      8. EXERCISES
  6. III. JOIN DEPENDENCIES, FIFTH NORMAL FORM, AND RELATED MATTERS
    1. 9. JDs and 5NF (Informal)
      1. JOIN DEPENDENCIES—THE BASIC IDEA
      2. A RELVAR IN BCNF AND NOT 5NF
      3. CYCLIC RULES
      4. CONCLUDING REMARKS
      5. EXERCISES
    2. 10. JDs and 5NF (Formal)
      1. JOIN DEPENDENCIES
      2. FIFTH NORMAL FORM
      3. JDs IMPLIED BY KEYS
      4. A USEFUL THEOREM
      5. FDs AREN’T JDs
      6. UPDATE ANOMALIES REVISITED
      7. EXERCISES
    3. 11. Implicit Dependencies
      1. IRRELEVANT COMPONENTS
      2. COMBINING COMPONENTS
      3. IRREDUCIBLE JDs
      4. SUMMARY SO FAR
      5. THE CHASE ALGORITHM
      6. CONCLUDING REMARKS
      7. EXERCISES
    4. 12. MVDs and 4NF
      1. AN INTRODUCTORY EXAMPLE
      2. MULTIVALUED DEPENDENCIES (INFORMAL)
      3. MULTIVALUED DEPENDENCIES (FORMAL)
      4. FOURTH NORMAL FORM
      5. AXIOMATIZATION
      6. EMBEDDED DEPENDENCIES
      7. EXERCISES
    5. 13. Additional Normal Forms
      1. EQUALITY DEPENDENCIES
      2. SIXTH NORMAL FORM
      3. SUPERKEY NORMAL FORM
      4. REDUNDANCY FREE NORMAL FORM
      5. DOMAIN-KEY NORMAL FORM
      6. CONCLUDING REMARKS
        1. Elementary key normal form (EKNF)
        2. Overstrong PJ/NF
        3. “Restriction-union” normal form
      7. EXERCISES
  7. IV. ORTHOGONALITY
    1. 14. The Principle of Orthogonal Design
      1. TWO CHEERS FOR NORMALIZATION
      2. A MOTIVATING EXAMPLE
      3. A SIMPLER EXAMPLE
      4. TUPLES vs. PROPOSITIONS
      5. THE FIRST EXAMPLE REVISITED
      6. THE SECOND EXAMPLE REVISITED
      7. THE FINAL VERSION
      8. A CLARIFICATION
      9. CONCLUDING REMARKS
      10. EXERCISES
  8. V. REDUNDANCY
    1. 15. We Need More Science
      1. A LITTLE HISTORY
      2. DATABASE DESIGN IS PREDICATE DESIGN
      3. EXAMPLE 1
      4. EXAMPLE 2
      5. EXAMPLE 3
      6. EXAMPLE 4
      7. EXAMPLE 5
      8. EXAMPLE 6
      9. EXAMPLE 7
      10. EXAMPLE 8
      11. EXAMPLE 9
      12. EXAMPLE 10
      13. EXAMPLE 11
      14. EXAMPLE 12
      15. MANAGING REDUNDANCY
        1. 1. Raw Design Only
        2. 2. Declare the Constraint
        3. 3. Use a View
        4. 4. Use a Snapshot
      16. REFINING THE DEFINITION
        1. Examples 1-2
        2. Example 3
        3. Example 4
        4. Example 5
        5. Example 6
        6. Example 7
        7. Example 8
        8. Example 9
        9. Example 10
        10. Example 11
        11. Example 12
      17. CONCLUDING REMARKS
      18. EXERCISES
  9. VI. APPENDIXES
    1. A. Primary Keys Are Nice but Not Essential
      1. ARGUMENTS IN DEFENSE OF THE PK:AK DISTINCTION
      2. RELVARS WITH MORE THAN ONE KEY
      3. THE INVOICES AND SHIPMENTS EXAMPLE
      4. ONE PRIMARY KEY PER ENTITY TYPE?
      5. THE APPLICANTS AND EMPLOYEES EXAMPLE
      6. CONCLUDING REMARKS
    2. B. Redundancy Revisited
    3. C. Historical Notes
    4. D. Answers to Exercises
      1. CHAPTER 1
      2. CHAPTER 2
      3. CHAPTER 3
      4. CHAPTER 4
      5. CHAPTER 5
      6. CHAPTER 6
      7. CHAPTER 7
      8. CHAPTER 8
      9. CHAPTER 9
      10. CHAPTER 10
      11. CHAPTER 11
      12. CHAPTER 12
      13. CHAPTER 13
      14. CHAPTER 14
      15. CHAPTER 15
  10. Index
  11. About the Author
  12. Copyright

Product information

  • Title: Database Design and Relational Theory
  • Author(s): C.J. Date
  • Release date: April 2012
  • Publisher(s): O'Reilly Media, Inc.
  • ISBN: 9781449328016