Combining schemas. Problems: redundancy, hard to update, possible NULLs
|
|
- Avice Marsh
- 5 years ago
- Views:
Transcription
1 Handout
2 Combining schemas Problems: redundancy, hard to update, possible NULLs
3 Problems? Conclusion: Whether the join attribute is PK or not makes a great difference when combining schemas!
4 Splitting schemas, a.k.a. decomposition (revert arrows below) Coincidence or not? (And why it matters ) Functional dependency: loan_number amount
5 An even worse decomposition: lossy! Why do we say lossy when in fact we end up with more data?
6
7 7.3 Decomposition using FDs
8
9 FD algebra
10 Example:
11 The most useful normal form:
12 loan = (loan_number, amount) borrower = (customer_id, loan_number) Find the set of all (non-trivial) FDs for the relation bor_loan
13 Another example: Is this schema in BCNF?
14 In bor_loan, the violating FD is loan_number amount, so we set Why not simply say R?
15 Another example: It was found earlier that this schema is not in BCNF. The violating FD is B C. Apply the BCNF decomposition algorithm!
16
17 If no, decompose it! Is this relation in BCNF?
18 To do for next time: Rework all the BCNF examples!
19 BCNF and preservation of dependencies E-R design from Ch.6: a customer A customer can have more than 1 personal banker, can have at most 1 personal banker but at most one at any given branch. (?)
20 A ternary relationship-set is needed: Implementation: R = cust_banker_branch = (customer_id, employee_id, branch_name, type) FDs: FD1: employee_id branch_name FD2: (customer_id, branch_name) (employee_id, type)
21 Is cust_banker_branch in BCNF? No. Apply the decomposition algorithm! Decomposition: R1 = (employee_id, branch_name) R2 = (customer_id, employee_id, type) Problem: FD2 is now spread across two relations!
22 Conclusion: BCNF is not dependency preserving R = cust_banker_branch = (customer_id, employee_id, branch_name, type) FDs: FD1: employee_id branch_name FD2: (customer_id, branch_name) (employee_id, type) Extra-credit: What if we started BCNF decomposition with F2 instead of F1? Time: 2
23 Because it is not always possible to achieve both BCNF and dependency preservation, we consider a weaker NF, known as Show that cust_banker_branch is in 3NF R = cust_banker_branch = (customer_id, employee_id, branch_name, type) FDs: FD1: employee_id branch_name FD2: (customer_id, branch_name) (employee_id, type)
24 Whatever happened to 2NF? In a nutshell, it forbids attributes to depend on parts of keys. See Second normal form - Wikipedia, the free encyclopedia for more details. Another BCNF/3NF example: books (B-Name, Ed, A-Name, A-SSN, Nr-pag) Is it in BCNF? 3NF? A_Name A_SSN To do for next time: Rework all the BCNF & 3NF examples!
25 Higher NFs Consider this relation: classes (course, teacher, book ) If (c, t, b) classes means that t is qualified to teach c, and b is a required textbook for c. What are the FDs for this relation? Is it in BCNF? Is it in 3NF?
26 We still have redundancies and insertion anomalies e.g., if Marilyn is a new teacher that can teach database, two tuples need to be inserted: (database, Marilyn, DB Concepts) (database, Marilyn, Ullman)
27
28 Whatever happened to 2NF? In a nutshell, it forbids attributes to depend on parts of keys. See Second normal form - Wikipedia, the free encyclopedia for more details.
29 The big picture
30 7.4 FD Theory The Closure of a set of FDs Yes, this is a trivial FD!
31 Algorithm to compute F+
32 Although Armstrong s axioms are sufficient to obtain the closure in practice we want more tools How about these? Idempotency: X X X Commutativity: X Y Y X They are true, but it is customary to write all attributes as sets w/no repeating values and sorted in alphabetical order.
33 Important lemma: if and only if Proof: Left as individual work for next time. Use the definition of a FD from p.271:
34 Practice exercise 7.4
35 Example: Quiz: Generate 4 more FDs that are in F +
36 7.4.2 The Closure of a set of attributes (under the set of FDs) Compare to the inefficient algorithm, based on F + For next time: Read and understand the example on p
37 Applications of attribute closure: Check if a set of attributes is superkey Check if a set of attributes is candidate key (i.e. superkey + minimal) Check if a functional dependency holds (i.e. if is in F + ) o Find + and then check if + Computing closure F + of F o For each set of attributes R, find the closure +, and for each S + output a functional dependency S Attribute closure gives another algorithm to find the FD closure F +! Compare it with the first alg. from fig Which one do you think is more efficient? Explain!
38 Example:
39 In general, a FD is of the form, with and sets of attributes, e.g. EFG KL. Food for thought: Can be the empty set? ( nothing ) Can be the total set? ( everything ) Can be the empty set? ( nothing ) Can be the total set? ( everything )
40 Extraneous attributes This part is trivial, so it doesn t need to be checked (it was included just for symmetry) In English: If we remove the attribute, the closure F + does not change Why is this of practical importance?
41 Examples: Given F = {A C, AB C } B is extraneous in AB C because {AB C} can be derived from A C (How?) As seen in this example, sometimes removal of extraneous attributes makes an entire FD disappear (b/c it s a duplicate) Given F = {A C, AB CD} C is extraneous in AB CD since AB C can be derived even after deleting C (How?)
42 Algorithm: Add to the list of applications of attribute closure! Exercise
43 Answer: Exercise
44 Answer: A+ = {A, B, C, D}, so A+ contains C, so C is extraneous in A CD Exercise Same scenario as above. Is D extraneous in A CD? Exercise F = {A B, B C, A C). Is C extraneous in A C? So what do we do about A C? For next time: solve all the exercises above, plus the one on p.283!
45 ? Why is this of practical importance? Algorithm:
46
47 Example not from text: Solve for practice!
48 Solution:
49 Two things must be preserved when we perform decompositions: Data (tuples) FDs
50 Efficient algorithm (uses only attribute closure, not FD closure!) How much of Ri can we recover, based on the current result?
51 Example (not in text, but in text slides): Trivial, don t need algorithm! Apply the algorithm above to prove this!
52 Solution: Prove that the decomposition R1=(A, B) R2 = (A,C) is not dependency preserving. The FD that needs to be recovered is B C. Apply algorithm: result = {B} Consider R1; result R1 = {B}; {B} + = {BC}; {BC} R1 = {B}; resultu{b} = {B} Consider R2; result R2 = Ø; Ø + = Ø; result = {B} No progress, so algorithm stops. We could not obtain the RHS of B C, so FD cannot be recovered.
53 Week 12, Lect Decomposition using FDs Problem: The definitions of both BCNF and 3NF require F + expensive!
54 FYI there is a sketched proof for this on p.289 (not required for final)
55 Can you find super-keys? Intuitively, we can feel that AC BDE but how to prove it? Hint: Armstrong s axioms (and theorems) So AC is a super-key. But is it a candidate key? (What s the difference?)
56 Do you think there are other candidate keys? Why or why not? Are there any BCNF violations? Hint: To find BCNF violations, do we need to check F or F +? Why? Which one do choose to start decomposition?
57 Now write down the two relations resulting from decomposition, including their FDs F 1 and F 2 and their candidate keys:
58
59
60 SKIP the remainder of Section 7.5, starting with (p.289) SKIP 7.6, 7.7 Read and take notes: Sections 7.8, 7.9 Homework for Ch.7: 1, 3, 5, 6, 7, 11
Chapter 7: Relational Database Design
Chapter 7: Relational Database Design Database System Concepts, 5th Ed. See www.db-book.com for conditions on re-use Chapter 7: Relational Database Design Features of Good Relational Design Atomic Domains
More informationChapter 6: Relational Database Design
Chapter 6: Relational Database Design Chapter 6: Relational Database Design Features of Good Relational Design Atomic Domains and First Normal Form Decomposition Using Functional Dependencies Second Normal
More informationcustomer = (customer_id, _ customer_name, customer_street,
Relational Database Design COMPILED BY: RITURAJ JAIN The Banking Schema branch = (branch_name, branch_city, assets) customer = (customer_id, _ customer_name, customer_street, customer_city) account = (account_number,
More informationCSE 544 Principles of Database Management Systems. Magdalena Balazinska Winter 2009 Lecture 4 - Schema Normalization
CSE 544 Principles of Database Management Systems Magdalena Balazinska Winter 2009 Lecture 4 - Schema Normalization References R&G Book. Chapter 19: Schema refinement and normal forms Also relevant to
More informationFunctional Dependencies CS 1270
Functional Dependencies CS 1270 Constraints We use constraints to enforce semantic requirements on a DBMS Predicates that the DBMS must ensure to be always true. Predicates are checked when the DBMS chooses
More informationChapter 8: Relational Database Design
Chapter 8: Relational Database Design Database System Concepts, 6 th Ed. See www.db-book.com for conditions on re-use Chapter 8: Relational Database Design Features of Good Relational Design Atomic Domains
More informationCS411 Database Systems. 05: Relational Schema Design Ch , except and
CS411 Database Systems 05: Relational Schema Design Ch. 3.1-3.5, except 3.4.2-3.4.3 and 3.5.3. 1 How does this fit in? ER Diagrams: Data Definition Translation to Relational Schema: Data Definition Relational
More informationDatabase Design Principles
Database Design Principles CPS352: Database Systems Simon Miner Gordon College Last Revised: 2/11/15 Agenda Check-in Design Project ERD Presentations Database Design Principles Decomposition Functional
More informationCSE 562 Database Systems
Goal CSE 562 Database Systems Question: The relational model is great, but how do I go about designing my database schema? Database Design Some slides are based or modified from originals by Magdalena
More informationCSE 544 Principles of Database Management Systems. Magdalena Balazinska Fall 2009 Lecture 3 - Schema Normalization
CSE 544 Principles of Database Management Systems Magdalena Balazinska Fall 2009 Lecture 3 - Schema Normalization References R&G Book. Chapter 19: Schema refinement and normal forms Also relevant to this
More informationRelational Database Design (II)
Relational Database Design (II) 1 Roadmap of This Lecture Algorithms for Functional Dependencies (cont d) Decomposition Using Multi-valued Dependencies More Normal Form Database-Design Process Modeling
More informationFunctional Dependencies
Functional Dependencies Redundancy in Database Design A table Students-take-courses (stud-id, name, address, phone, crs-id, instructor-name, office) Students(stud-id, name, address, phone, ) Instructors(name,
More informationUnit 3 : Relational Database Design
Unit 3 : Relational Database Design Database System Concepts, 6 th Ed. See www.db-book.com for conditions on re-use Content Relational Model: Basic concepts, Attributes and Domains, CODD's Rules, Relational
More informationDatabase design III. Quiz time! Using FDs to detect anomalies. Decomposition. Decomposition. Boyce-Codd Normal Form 11/4/16
Lecture 3 Quiz time! Database design III Functional dependencies cont. BCNF and 3NF What s wrong with this schema? {(, 2, Databases, Steven Van Acker ), (, 4, Databases, Rogardt Heldal )} Redundancy! Using
More informationHomework 6: FDs, NFs and XML (due April 13 th, 2016, 4:00pm, hard-copy in-class please)
Virginia Tech. Computer Science CS 4604 Introduction to DBMS Spring 2016, Prakash Homework 6: FDs, NFs and XML (due April 13 th, 2016, 4:00pm, hard-copy in-class please) Reminders: a. Out of 100 points.
More informationDatabases Tutorial. March,15,2012 Jing Chen Mcmaster University
Databases Tutorial March,15,2012 Jing Chen Mcmaster University Outline 1NF Functional Dependencies BCNF 3NF Larger Schema Suppose we combine borrower and loan to get bor_loan - borrower = (customer_id,
More informationUNIT 3 DATABASE DESIGN
UNIT 3 DATABASE DESIGN Objective To study design guidelines for relational databases. To know about Functional dependencies. To have an understanding on First, Second, Third Normal forms To study about
More informationFunctional dependency theory
Functional dependency theory Introduction to Database Design 2012, Lecture 8 Course evaluation Recalling normal forms Functional dependency theory Computing closures of attribute sets BCNF decomposition
More informationPart II: Using FD Theory to do Database Design
Part II: Using FD Theory to do Database Design 32 Recall that poorly designed table? part manufacturer manaddress seller selleraddress price 1983 Hammers R Us 99 Pinecrest ABC 1229 Bloor W 5.59 8624 Lee
More informationLecture 11 - Chapter 8 Relational Database Design Part 1
CMSC 461, Database Management Systems Spring 2018 Lecture 11 - Chapter 8 Relational Database Design Part 1 These slides are based on Database System Concepts 6th edition book and are a modified version
More informationCMU SCS CMU SCS CMU SCS CMU SCS whole nothing but
Faloutsos & Pavlo 15-415/615 Carnegie Mellon Univ. Dept. of Computer Science 15-415/615 - DB Applications Lecture #17: Schema Refinement & Normalization - Normal Forms (R&G, ch. 19) Overview - detailed
More informationDatabase Management System Prof. Partha Pratim Das Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur
Database Management System Prof. Partha Pratim Das Department of Computer Science & Engineering Indian Institute of Technology, Kharagpur Lecture - 19 Relational Database Design (Contd.) Welcome to module
More informationDatabase Design Theory and Normalization. CS 377: Database Systems
Database Design Theory and Normalization CS 377: Database Systems Recap: What Has Been Covered Lectures 1-2: Database Overview & Concepts Lecture 4: Representational Model (Relational Model) & Mapping
More informationCSIT5300: Advanced Database Systems
CSIT5300: Advanced Database Systems L06: Relational Database Design BCNF Dr. Kenneth LEUNG Department of Computer Science and Engineering The Hong Kong University of Science and Technology Hong Kong SAR,
More informationDatabase Systems. Basics of the Relational Data Model
Database Systems Relational Design Theory Jens Otten University of Oslo Jens Otten (UiO) Database Systems Relational Design Theory INF3100 Spring 18 1 / 30 Basics of the Relational Data Model title year
More informationHomework 6: FDs, NFs and XML (due April 15 th, 2015, 4:00pm, hard-copy in-class please)
Virginia Tech. Computer Science CS 4604 Introduction to DBMS Spring 2015, Prakash Homework 6: FDs, NFs and XML (due April 15 th, 2015, 4:00pm, hard-copy in-class please) Reminders: a. Out of 100 points.
More informationCarnegie Mellon Univ. Dept. of Computer Science /615 - DB Applications. Overview - detailed. Goal. Faloutsos & Pavlo CMU SCS /615
Faloutsos & Pavlo 15-415/615 Carnegie Mellon Univ. Dept. of Computer Science 15-415/615 - DB Applications Lecture #17: Schema Refinement & Normalization - Normal Forms (R&G, ch. 19) Overview - detailed
More informationLecture 4. Database design IV. INDs and 4NF Design wrapup
Lecture 4 Database design IV INDs and 4NF Design wrapup Problem description We want a database that we can use for scheduling courses and lectures. This is how it s supposed to work: code name Course dept
More informationHandout 3: Functional Dependencies and Normalization
Virginia Tech. Computer Science CS 4604 Introduction to DBMS Spring 2015, Prakash Handout 3: Functional Dependencies and Normalization Q1: Inferring FDs Consider the following schemas and sets of functional
More informationFUNCTIONAL DEPENDENCIES
FUNCTIONAL DEPENDENCIES CS 564- Spring 2018 ACKs: Dan Suciu, Jignesh Patel, AnHai Doan WHAT IS THIS LECTURE ABOUT? Database Design Theory: Functional Dependencies Armstrong s rules The Closure Algorithm
More informationDatabases Lecture 7. Timothy G. Griffin. Computer Laboratory University of Cambridge, UK. Databases, Lent 2009
Databases Lecture 7 Timothy G. Griffin Computer Laboratory University of Cambridge, UK Databases, Lent 2009 T. Griffin (cl.cam.ac.uk) Databases Lecture 7 DB 2009 1 / 17 Lecture 07: Decomposition to Normal
More informationNormalization. Murali Mani. What and Why Normalization? To remove potential redundancy in design
1 Normalization What and Why Normalization? To remove potential redundancy in design Redundancy causes several anomalies: insert, delete and update Normalization uses concept of dependencies Functional
More informationDesign Theory for Relational Databases
Design Theory for Relational Databases csc343, fall 2014 Diane Horton University of Toronto Originally based on slides by Jeff Ullman 1 Introduction There are always many different schemas for a given
More informationRelational Database Design Theory. Introduction to Databases CompSci 316 Fall 2017
Relational Database Design Theory Introduction to Databases CompSci 316 Fall 2017 2 Announcements (Thu. Sep. 14) Homework #1 due next Tuesday (11:59pm) Course project description posted Read it! Mixer
More informationHomework 3: Relational Database Design Theory (100 points)
CS 122A: Introduction to Data Management Spring 2018 Homework 3: Relational Database Design Theory (100 points) Due Date: Wed, Apr 25 (5:00 PM) Submission All HW assignments should be turned in with a
More informationDatabases -Normalization I. (GF Royle, N Spadaccini ) Databases - Normalization I 1 / 24
Databases -Normalization I (GF Royle, N Spadaccini 2006-2010) Databases - Normalization I 1 / 24 This lecture This lecture introduces normal forms, decomposition and normalization. We will explore problems
More informationPresentation on Functional Dependencies CS x265
Presentation on Functional Dependencies CS x265 This presentation assumes that you have previously viewed Watch videos (90 min) and answer questions from DB8 Relational Design Theory (https://class.stanford.edu/courses/db/rd/selfpaced/courseware/ch-relational_design_theory/)
More informationRelational Design: Characteristics of Well-designed DB
1. Minimal duplication Relational Design: Characteristics of Well-designed DB Consider table newfaculty (Result of F aculty T each Course) Id Lname Off Bldg Phone Salary Numb Dept Lvl MaxSz 20000 Cotts
More informationCSCI 403: Databases 13 - Functional Dependencies and Normalization
CSCI 403: Databases 13 - Functional Dependencies and Normalization Introduction The point of this lecture material is to discuss some objective measures of the goodness of a database schema. The method
More informationBCNF. Yufei Tao. Department of Computer Science and Engineering Chinese University of Hong Kong BCNF
Yufei Tao Department of Computer Science and Engineering Chinese University of Hong Kong Recall A primary goal of database design is to decide what tables to create. Usually, there are two principles:
More informationDatabases The theory of relational database design Lectures for m
Databases The theory of relational database design Lectures for mathematics students April 2, 2017 General introduction Look; that s why there s rules, understand? So that you think before you break em.
More informationCS352 Lecture - Conceptual Relational Database Design
CS352 Lecture - Conceptual Relational Database Design Objectives: last revised September 20, 2006 1. To define the concepts functional dependency and multivalued dependency 2. To show how to find the closure
More informationDraw A Relational Schema And Diagram The Functional Dependencies In The Relation >>>CLICK HERE<<<
Draw A Relational Schema And Diagram The Functional Dependencies In The Relation I need to draw relational schema and dependency diagram showing transitive and partial Functional dependency and normalization
More informationCS352 Lecture - Conceptual Relational Database Design
CS352 Lecture - Conceptual Relational Database Design Objectives: last revised September 16, 2004 1. To define the concepts functional dependency and multivalued dependency 2. To show how to find the closure
More informationNORMAL FORMS. CS121: Relational Databases Fall 2017 Lecture 18
NORMAL FORMS CS121: Relational Databases Fall 2017 Lecture 18 Equivalent Schemas 2 Many different schemas can represent a set of data Which one is best? What does best even mean? Main goals: Representation
More informationNormalization 03. CSE3421 notes
Normalization 03 CSE3421 notes 1 Example F: A B (1) ABCD E (2) EF G (3) EF H (4) ACDF EG (5) Calculate the minimal cover of F. 2 Step 1: Put F in standard form FDs (1) (4) are already in standard form.
More informationThis lecture. Databases -Normalization I. Repeating Data. Redundancy. This lecture introduces normal forms, decomposition and normalization.
This lecture Databases -Normalization I This lecture introduces normal forms, decomposition and normalization (GF Royle 2006-8, N Spadaccini 2008) Databases - Normalization I 1 / 23 (GF Royle 2006-8, N
More informationNormalization. Anomalies Functional Dependencies Closures Key Computation Projecting Relations BCNF Reconstructing Information Other Normal Forms
Anomalies Functional Dependencies Closures Key Computation Projecting Relations BCNF Reconstructing Information Other Normal Forms Normalization Niklas Fors (niklas.fors@cs.lth.se) Normalization 1 / 45
More informationLecture 6a Design Theory and Normalization 2/2
CompSci 516 Data Intensive Computing Systems Lecture 6a Design Theory and Normalization 2/2 Instructor: Sudeepa Roy 1 HW1 deadline: Announcements Due on 09/21 (Thurs), 11:55 pm, no late days Project proposal
More information6.830 Lecture PS1 Due Next Time (Tuesday!) Lab 1 Out end of week start early!
6.830 Lecture 3 9.13.2017 PS1 Due Next Time (Tuesday!) Lab 1 Out end of week start early! Relational Model Continued, and Schema Design and Normalization Animals(name,age,species,cageno,keptby,feedtime)
More informationFundamentals of Database Systems
Fundamentals of Database Systems Assignment: 3 Due Date: 23st August, 2017 Instructions This question paper contains 15 questions in 6 pages. Q1: Consider the following relation and its functional dependencies,
More informationNormalisation theory
Normalisation theory Introduction to Database Design 2012, Lecture 7 Challenging exercises E-R diagrams example Normalisation theory, motivation Functional dependencies Boyce-Codd normal form (BCNF) 3rd
More informationSchema Refinement & Normalization Theory 2. Week 15
Schema Refinement & Normalization Theory 2 Week 15 1 How do we know R is in BCNF? If R has only two attributes, then it is in BCNF If F only uses attributes in R, then: R is in BCNF if and only if for
More informationReview: Attribute closure
CS445 - Introduction to Database Management Systems Fall Semester 2015 LECTURE 10 Functional Dependencies, Normalization Part II TEXTBOOK REFERENCE: CHAPTER 19 CS445 DATABASES: LECTURE 10 1 Review: Attribute
More informationCOSC Dr. Ramon Lawrence. Emp Relation
COSC 304 Introduction to Database Systems Normalization Dr. Ramon Lawrence University of British Columbia Okanagan ramon.lawrence@ubc.ca Normalization Normalization is a technique for producing relations
More informationLectures 5 & 6. Lectures 6: Design Theory Part II
Lectures 5 & 6 Lectures 6: Design Theory Part II Lecture 6 Today s Lecture 1. Boyce-Codd Normal Form ACTIVITY 2. Decompositions & 3NF ACTIVITY 3. MVDs ACTIVITY 2 Lecture 6 > Section 1 1. Boyce-Codd Normal
More informationInformal Design Guidelines for Relational Databases
Outline Informal Design Guidelines for Relational Databases Semantics of the Relation Attributes Redundant Information in Tuples and Update Anomalies Null Values in Tuples Spurious Tuples Functional Dependencies
More informationDesired properties of decompositions
Desired properties of decompositions We expect that after decomposition No anomalies and redundancies We can recover the original relation from the tuples in its decompositions We can ensure that after
More informationThe Relational Data Model
The Relational Data Model Lecture 6 1 Outline Relational Data Model Functional Dependencies Logical Schema Design Reading Chapter 8 2 1 The Relational Data Model Data Modeling Relational Schema Physical
More informationQUESTION BANK. SUBJECT CODE / Name: CS2255 DATABASE MANAGEMENT SYSTEM UNIT III. PART -A (2 Marks)
QUESTION BANK DEPARTMENT: CSE SEMESTER: IV SUBJECT CODE / Name: CS2255 DATABASE MANAGEMENT SYSTEM UNIT III PART -A (2 Marks) 1. Explain the two conditions needed for the set difference operation (union
More informationAdministrivia. Carnegie Mellon Univ. Dept. of Computer Science /615 - DB Applications. Relational Model: Keys. Correction: Implied FDs
Carnegie Mellon Univ. Dept. of Computer Science 15-415/615 - DB Applications Administrivia HW6 is due Tuesday March 24 th. C. Faloutsos A. Pavlo Lecture#17: Schema Refinement & Normalization Faloutsos/Pavlo
More informationCase Study: Lufthansa Cargo Database
Case Study: Lufthansa Cargo Database Carsten Schürmann 1 Today s lecture More on data modelling Introduction to Lufthansa Cargo Database Entity Relationship diagram Boyce-Codd normal form 2 From Lecture
More informationNormalisation Chapter2 Contents
Contents Objective... 64 Superkey & Candidate Keys... 65 Primary, Alternate and Foreign Keys... 65 Functional Dependence... 67 Using Instances... 70 Normalisation Introduction... 70 Normalisation Problems...
More informationFunctional Dependencies and Finding a Minimal Cover
Functional Dependencies and Finding a Minimal Cover Robert Soulé 1 Normalization An anomaly occurs in a database when you can update, insert, or delete data, and get undesired side-effects. These side
More informationTheory of Normal Forms Decomposition of Relations. Overview
.. Winter 2008 CPE/CSC 366: Database Modeling, Design and Implementation Alexander Dekhtyar.. Overview Theory of Normal Forms Decomposition of Relations Functional Dependencies capture the attribute dependencies
More informationUNIT -III. Two Marks. The main goal of normalization is to reduce redundant data. Normalization is based on functional dependencies.
UNIT -III Relational Database Design: Features of Good Relational Designs- Atomic Domains and First Normal Form- Second Normal Form-Decomposition Using Functional Dependencies- Functional-Dependency Theory-Algorithms
More informationDatabase Management
Database Management - 2011 Model Answers 1. a. A data model should comprise a structural part, an integrity part and a manipulative part. The relational model provides standard definitions for all three
More informationDatabase Systems CSE Comprehensive Exam Spring 2005
Database Systems CSE 5260 Spring 2005 Database Schema #1 Branch (Branch_Name, Branch_City, Assets) Customer (Customer_Name, SS#, Street, City, State, Zip_Code) Account (Account_Number, Branch_Name, Balance)
More informationDesirable database characteristics Database design, revisited
CMPT 354 Desirable database characteristics Database design, revisited Normal Forms First Normal Form Second Normal Form Third Normal Form Boyce-Codd Normal Form Normal forms and functional dependencies
More informationMore Normalization Algorithms. CS157A Chris Pollett Nov. 28, 2005.
More Normalization Algorithms CS157A Chris Pollett Nov. 28, 2005. Outline 3NF Decomposition Algorithms BCNF Algorithms Multivalued Dependencies and 4NF Dependency-Preserving Decomposition into 3NF Input:
More informationSchema Refinement: Dependencies and Normal Forms
Schema Refinement: Dependencies and Normal Forms Grant Weddell David R. Cheriton School of Computer Science University of Waterloo CS 348 Introduction to Database Management Spring 2012 CS 348 (Intro to
More informationRelational Design 1 / 34
Relational Design 1 / 34 Relational Design Basic design approaches. What makes a good design better than a bad design? How do we tell we have a "good" design? How to we go about creating a good design?
More informationCS 338 Functional Dependencies
CS 338 Functional Dependencies Bojana Bislimovska Winter 2016 Outline Design Guidelines for Relation Schemas Functional Dependency Set and Attribute Closure Schema Decomposition Boyce-Codd Normal Form
More informationAssignment 2 Solutions
CMPT 354 Database Systems I Assignment 2 Solutions Due: Friday, June 23 th, 2006, at the start of class 1. Normalizing relations eliminates redundancy, which is a cause for database anomalies such as inconsistencies
More informationIn This Lecture. Normalisation to BCNF. Lossless decomposition. Normalisation so Far. Relational algebra reminder: product
In This Lecture Normalisation to BCNF Database Systems Lecture 12 Natasha Alechina More normalisation Brief review of relational algebra Lossless decomposition Boyce-Codd normal form (BCNF) Higher normal
More informationDATABASE MANAGEMENT SYSTEMS
www..com Code No: N0321/R07 Set No. 1 1. a) What is a Superkey? With an example, describe the difference between a candidate key and the primary key for a given relation? b) With an example, briefly describe
More informationDatabase Normalization. (Olav Dæhli 2018)
Database Normalization (Olav Dæhli 2018) 1 What is normalization and why normalize? Normalization: A set of rules to decompose relations (tables) into smaller relations (tables), without loosing any data
More informationSchema Refinement: Dependencies and Normal Forms
Schema Refinement: Dependencies and Normal Forms Grant Weddell Cheriton School of Computer Science University of Waterloo CS 348 Introduction to Database Management Spring 2016 CS 348 (Intro to DB Mgmt)
More informationFunctional Dependencies & Normalization for Relational DBs. Truong Tuan Anh CSE-HCMUT
Functional Dependencies & Normalization for Relational DBs Truong Tuan Anh CSE-HCMUT 1 2 Contents 1 Introduction 2 Functional dependencies (FDs) 3 Normalization 4 Relational database schema design algorithms
More informationChapter 14 Outline. Normalization for Relational Databases: Outline. Chapter 14: Basics of Functional Dependencies and
Ramez Elmasri, Shamkant B. Navathe(2016) Fundamentals of Database Systems (7th Edition), pearson, isbn 10: 0-13-397077-9;isbn-13:978-0-13-397077-7. Chapter 14: Basics of Functional Dependencies and Normalization
More informationDesign Theory for Relational Databases
By Marina Barsky Design Theory for Relational Databases Lecture 15 Functional dependencies: formal definition X Y is an assertion about a relation R that whenever two tuples of R agree on all the attributes
More informationNormalisation. Normalisation. Normalisation
Normalisation Normalisation Main objective in developing a logical data model for relational database systems is to create an accurate and efficient representation of the data, its relationships, and constraints
More informationChapter 10. Chapter Outline. Chapter Outline. Functional Dependencies and Normalization for Relational Databases
Chapter 10 Functional Dependencies and Normalization for Relational Databases Chapter Outline 1 Informal Design Guidelines for Relational Databases 1.1Semantics of the Relation Attributes 1.2 Redundant
More informationChapter 10. Normalization. Chapter Outline. Chapter Outline(contd.)
Chapter 10 Normalization Chapter Outline 1 Informal Design Guidelines for Relational Databases 1.1Semantics of the Relation Attributes 1.2 Redundant Information in Tuples and Update Anomalies 1.3 Null
More informationLectures 12: Design Theory I. 1. Normal forms & functional dependencies 2/19/2018. Today s Lecture. What you will learn about in this section
Today s Lecture Lectures 12: Design Theory I Professor Xiannong Meng Spring 2018 Lecture and activity contents are based on what Prof Chris Ré used in his CS 145 in the fall 2016 term with permission 1.
More informationDATABASE DESIGN I - 1DL300
DATABASE DESIGN I - 1DL300 Spring 2013 An Introductory Course on Database Systems http://www.it.uu.se/edu/course/homepage/dbastekn/vt13/ Uppsala Database Laboratory Department of Information Technology,
More informationIntroduction to Databases, Fall 2003 IT University of Copenhagen. Lecture 4: Normalization. September 16, Lecturer: Rasmus Pagh
Introduction to Databases, Fall 2003 IT University of Copenhagen Lecture 4: Normalization September 16, 2003 Lecturer: Rasmus Pagh Today s lecture What you should remember from previously. Anomalies in
More informationSCHEMA REFINEMENT AND NORMAL FORMS
19 SCHEMA REFINEMENT AND NORMAL FORMS Exercise 19.1 Briefly answer the following questions: 1. Define the term functional dependency. 2. Why are some functional dependencies called trivial? 3. Give a set
More informationLecture 14 of 42. E-R Diagrams, UML Notes: PS3 Notes, E-R Design. Thursday, 15 Feb 2007
Lecture 14 of 42 E-R Diagrams, UML Notes: PS3 Notes, E-R Design Thursday, 15 February 2007 William H. Hsu Department of Computing and Information Sciences, KSU KSOL course page: http://snipurl.com/va60
More informationLecture 5 Design Theory and Normalization
CompSci 516 Data Intensive Computing Systems Lecture 5 Design Theory and Normalization Instructor: Sudeepa Roy Duke CS, Fall 2017 CompSci 516: Database Systems 1 HW1 deadline: Announcements Due on 09/21
More informationDATABASE DESIGN I - 1DL300
DATABASE DESIGN I - 1DL300 Autumn 2012 An Introductory Course on Database Systems http://www.it.uu.se/edu/course/homepage/dbastekn/ht12/ Uppsala Database Laboratory Department of Information Technology,
More informationCopyright 2016 Ramez Elmasri and Shamkant B. Navathe
CHAPTER 14 Basics of Functional Dependencies and Normalization for Relational Databases Slide 14-2 Chapter Outline 1 Informal Design Guidelines for Relational Databases 1.1 Semantics of the Relation Attributes
More informationSchema Refinement and Normal Forms
Schema Refinement and Normal Forms Chapter 19 Quiz #2 Next Wednesday Comp 521 Files and Databases Fall 2010 1 The Evils of Redundancy Redundancy is at the root of several problems associated with relational
More informationChapter 16. Relational Database Design Algorithms. Database Design Approaches. Top-Down Design
Chapter 16 Relational Database Design Algorithms Database Design Approaches Top-Down design (Starting with conceptual design) Bottom-Up Design (relational synthesis) 2 Top-Down Design Design conceptual
More informationChapter 14. Database Design Theory: Introduction to Normalization Using Functional and Multivalued Dependencies
Chapter 14 Database Design Theory: Introduction to Normalization Using Functional and Multivalued Dependencies Copyright 2012 Ramez Elmasri and Shamkant B. Navathe Chapter Outline 1 Informal Design Guidelines
More informationRelational Model and Relational Algebra A Short Review Class Notes - CS582-01
Relational Model and Relational Algebra A Short Review Class Notes - CS582-01 Tran Cao Son January 12, 2002 0.1 Basics The following definitions are from the book [1] Relational Model. Relations are tables
More informationRelational Design Theory
Chapter 5 Relational Design Theory Database Systems p. 211/569 Relational Design Theory A badly designed schema can cause a lot of trouble Database designers talk of anomalies and distinguish three different
More informationADVANCED DATABASES ; Spring 2015 Prof. Sang-goo Lee (11:00pm: Mon & Wed: Room ) Advanced DB Copyright by S.-g.
4541.564; Spring 2015 Prof. Sang-goo Lee (11:00pm: Mon & Wed: Room 301-203) ADVANCED DATABASES Copyright by S.-g. Lee Review - 1 General Info. Text Book Database System Concepts, 6 th Ed., Silberschatz,
More informationCSCI 127 Introduction to Database Systems
CSCI 127 Introduction to Database Systems Integrity Constraints and Functional Dependencies Integrity Constraints Purpose: Prevent semantic inconsistencies in data e.g.: cname svngs check total Joe 100
More informationUnit- III (Functional dependencies and Normalization, Relational Data Model and Relational Algebra)
Unit- III (Functional dependencies and Normalization, Relational Data Model and Relational Algebra) Important questions Section A :(2 Marks) 1.What is Functional Dependency? Functional dependency (FD)
More information