Normalization. Normalization. First goal: to eliminate redundant data. for example, don t storing the same data in more than one table

Size: px
Start display at page:

Download "Normalization. Normalization. First goal: to eliminate redundant data. for example, don t storing the same data in more than one table"

Transcription

1 Normalization Normalization Purpose Redundancy and Data Anomalies 1FN: First Normal Form 2FN: Second Normal Form 3FN: Thrird Normal Form Examples 1 Normalization Normalization is the process of efficiently organizing data in a database with two goals in mind First goal: to eliminate redundant data for example, don t storing the same data in more than one table Second Goal: to ensure data dependencies make sense for example, only storing related data in a table 2 1

2 Normalization Purpose To avoid redundancy by storing each fact within the database only once. To put data into a form that conforms to relational principles (e.g., single valued attributes, each relation represents one entity) To put the data into a form that is more able to accurately accommodate change To facilitate the enforcement of data constraints. To avoid anomalies. Summary : All attributes in a table must be atomic, and solely dependant upon the fully primary key of that table. 3 The Solution: Normal Forms Bad database designs have: redundancy: inefficient storage. anomalies: data inconsistency, difficulties in maintenance 1NF, 2NF, 3NF, BCNF are some of the early forms in the list that address this problem 4 2

3 Redundancy and Data Anomalies Redundant data is where we have stored the same information more than once. i.e., the redundant data could be removed without the loss of information. Example: We have the following relation that contains staff and department details: staffno job dept dname city SL10 Salesman 10 Sales Stratford SA51 Manager 20 Accounts Barking DS40 Clerk 20 Accounts Barking OS45 Clerk 30 Operations Barking Such redundancy could lead to the following anomalies Insert Anomaly: We can t insert a dept without inserting a member of staff that works in that department Update Anomaly: We could change the name of the dept that SA51 works in without simultaneously changing the dept that DS40 works in. Deletion Anomaly: By removing employee SL10 we have removed all information pertaining to the Sales dept. 2010/2011 Topic #2: Normalization 5 (Relational Database Design) First Normal Form An atomic attribute cannot be decomposed into meaningful components: Examples: Gender (atomic) Price: $ Currency (dollar) plus number (May or may not be atomic) Name: John Smith. first name plus family name (May or may not be atomic) An scheme satisfies the first normal form (1NF) if all attribute values are atomic: no repeating groups, no composite attributes Do not try intelligent solutions in which a string can be parsed: B427 -> building B, floor 4, room

4 Second Normal Form Second normal form (2NF) addresses the concept of removing duplicate data R satisfies the 2NF if R is 1NF, and All non-prime attributes are fully dependent on the primary key Example registration(student_id, student_name, course_id, ( course_name Satisfies 1FN (if names are atomic) student_name depends on student_id but not on course_id Solution: split relation in three ( student_name student(student_id, ( course_name course(course_id, ( course_id registration(student_id, 8 Third Normal Form Remove columns that are not dependent upon the primary key Definition of transitive dependence: One attribute depends transitively on another if depends on an attribute that is not the primary key Example: ( client_name order(order_id, date, client_id, It satisfies 1FN y 2FN with primary key order_id But client_name changes if client_id changes Solution create two relations ( client_id order(order_id, date, ( client(client_id,client_name 9 4

5 Summary Steps in the Normalization process (up to 3NF): 1. Relation must have a fixed number of atomic attributes. 2. Identify primary key. 3. Check that all attributes (except primary key members) depend on the WHOLE primary key (not a part). 4. If partial dependency ((3) is not true) break the relation. 5. Check that the attributes don t depend on another attribute, which is not the primary key. 6. If transitive dependency ((5) is not true) break the relation. 10 ORDER Unnormalised Normal Form (UNF) Customer No: Order Number: Name: Mark Campbell Order Date: 14-Feb-2002 Address: 1 The House Leytonstone E11 9ZZ Product Product Unit Order Line Number Description Price Quantity Total T5060 Hook PT42 Bolt QZE48 Spanner Order Total: ORDER (order-no, order-date, cust-no, cust-name, cust-add, (prod-no, prod-desc, unit-price, ord-qty, line-total)*, order-total 2010/2011 Topic #2: Normalization 11 (Relational Database Design) 5

6 First Normal Form (1NF) Definition: A relation is in 1NF if, and only if, all its underlying attributes contain atomic values only. Remove repeating groups into a new relation A repeating group is shown by a pair of brackets within the relational schema. ORDER (order-no, order-date, cust-no, cust-name, cust-add, (prod-no, prod-desc, unit-price, ord-qty, line-total)*, order-total Steps from UNF to 1NF: Remove the outermost repeating group (and any nested repeated groups it may contain) and create a new relation to contain it. Add to this relation a copy of the PK of the relation immediately enclosing it. Name the new entity (appending the number 1 to indicate 1NF) Determine the PK of the new entity Repeat steps until no more repeating groups. 2010/2011 Topic #2: Normalization 12 (Relational Database Design) Example - UNF to 1NF ORDER (order-no, order-date, cust-no, cust-name, cust-add, (prod-no, prod-desc, unit-price, ord-qty, line-total)*, order-total 1. Remove the outermost repeating group (and any nested repeated groups it may contain) and create a new relation to contain it. (rename original to indicate 1NF) ORDER-1 (order-no, order-date, cust-no, cust-name, cust-add, order-total (prod-no, prod-desc, unit-price, ord-qty, line-total) 2. Add to this relation a copy of the PK of the relation immediately enclosing it. ORDER-1 (order-no, order-date, cust-no, cust-name, cust-add, order-total (order-no, prod-no, prod-desc, unit-price, ord-qty, line-total) 3. Name the new entity (appending the number 1 to indicate 1NF) ORDER-LINE-1 (order-no, prod-no, prod-desc, unit-price, ord-qty, line-total) 4. Determine the PK of the new entity ORDER-LINE-1 (order-no, prod-no, prod-desc, unit-price, ord-qty, line-total) 2010/2011 Topic #2: Normalization 13 (Relational Database Design) 6

7 Second Normal Form (2NF) Definition: A relation is in 2NF if, and only if, it is in 1NF and every non-key attribute is fully dependent on the primary key. Steps from 1NF to 2NF: Remove the offending attributes that are only partially functionally dependent on the composite key, and place them in a new relation. Remove partial functional dependencies into a new relation Add to this relation a copy of the attribute(s) which are the determinants of these offending attributes. These will automatically become the primary key of this new relation. Name the new entity (appending the number 2 to indicate 2NF) Rename the original entity (ending with a 2 to indicate 2NF) 2010/2011 Topic #2: Normalization 14 (Relational Database Design) Example - 1NF to 2NF ORDER-LINE-1 (order-no, prod-no, prod-desc, unit-price, ord-qty, line-total) 1. Remove the offending attributes that are only partially functionally dependent on the composite key, and place them in a new relation. ORDER-LINE-1 (order-no, prod-no, ord-qty, line-total) (prod-desc, unit-price) 2. Add to this relation a copy of the attribute(s) which determines these offending attributes. These will automatically become the primary key of this new relation.. ORDER-LINE-1 (order-no, prod-no, ord-qty, line-total) (prod-no, prod-desc, unit-price) 3. Name the new entity (appending the number 2 to indicate 2NF) PRODUCT-2 (prod-no, prod-desc, unit-price) 4. Rename the original entity (ending with a 2 to indicate 2NF) ORDER-LINE-2 (order-no, prod-no, ord-qty, line-total) 2010/2011 Topic #2: Normalization 15 (Relational Database Design) 7

8 Third Normal Form (3NF) Definition: A relation is in 3NF if, and only if, it is in 2NF and every non-key attribute is non-transitively dependent on the primary key. Remove transitive dependencies into a new relation Steps from 2NF to 3NF: Remove the offending attributes that are transitively dependent on non-key attribute(s), and place them in a new relation. Add to this relation a copy of the attribute(s) which are the determinants of these offending attributes. These will automatically become the primary key of this new relation. Name the new entity (appending the number 3 to indicate 3NF) Rename the original entity (ending with a 3 to indicate 3NF) 2010/2011 Topic #2: Normalization 16 (Relational Database Design) Example - 2NF to 3NF ORDER-2 (order-no, order-date, cust-no, cust-name, cust-add, order-total 1. Remove the offending attributes that are transitively dependent on non-key attributes, and place them in a new relation. ORDER-2 (order-no, order-date, cust-no, order-total (cust-name, cust-add ) 2. Add to this relation a copy of the attribute(s) which determines these offending attributes. These will automatically become the primary key of this new relation.. ORDER-2 (order-no, order-date, cust-no, order-total (cust-no, cust-name, cust-add ) 3. Name the new entity (appending the number 3 to indicate 3NF) CUSTOMER-3 (cust-no, cust-name, cust-add ) 4. Rename the original entity (ending with a 3 to indicate 3NF) ORDER-3 (order-no, order-date, cust-no, order-total 2010/2011 Topic #2: Normalization 17 (Relational Database Design) 8

9 Example - Relations in 3NF ORDER-3 (order-no, order-date, cust-no, order-total CUSTOMER-3 (cust-no, cust-name, cust-add ) PRODUCT-2 (prod-no, prod-desc, unit-price) ORDER-LINE-2 (order-no, prod-no, ord-qty, line-total) order-no ORDER prod-no PRODUCT places placed by contains shows belongs to cust-no part of order-no, prod-no CUSTOMER ORDER-LINE 2010/2011 Topic #2: Normalization 18 (Relational Database Design) Normalize: (1) ( date holiday(place_id, place_name, client_id, client_name, Atomic Attributes? Yes, it is 1FN 2FN All attributes (except those belonging to the primary key) depend on the whole primary key? place_name depends on place_id ( place_name create: place_2(place_id, client_name depends on client_id ( client_name create: client_2 (client_id, ( date and holiday_2 (place_id, client_id, Transitive Dependences? No transitive dependences 3FN 19 9

10 Normalize: (2) ( book(room_id,date,client_id,client_name Atomic Attributes? Yes, it is 1FN 2FN All attributes (except those belonging to the primary key) depend on the whole primary key? client_name depends on client_id create: client_2 (client_id, ( client_name book_2 (, room_id,date,client_id ) Transitive Dependences? No transitive dependences 3FN 20 10

Normalisation 6 TABLE OF CONTENTS LEARNING OUTCOMES

Normalisation 6 TABLE OF CONTENTS LEARNING OUTCOMES Topic Normalisation 6 LEARNING OUTCOMES When you have completed this Topic you should be able to: 1. Discuss importance of the normalisation in the database design. 2. Discuss the problems related to data

More information

Normalization. CIS 3730 Designing and Managing Data. J.G. Zheng Fall 2010

Normalization. CIS 3730 Designing and Managing Data. J.G. Zheng Fall 2010 Normalization CIS 3730 Designing and Managing Data J.G. Zheng Fall 2010 1 Overview What is normalization? What are the normal forms? How to normalize relations? 2 Two Basic Ways To Design Tables Bottom-up:

More information

Introduction to normalization. Introduction to normalization

Introduction to normalization. Introduction to normalization Introduction to normalization Lecture 4 Instructor Anna Sidorova Agenda Presentation Review of relational models, in class exersise Introduction to normalization In-class exercises Discussion of HW2 1

More information

COSC344 Database Theory and Applications. Lecture 9 Normalisation. COSC344 Lecture 9 1

COSC344 Database Theory and Applications. Lecture 9 Normalisation. COSC344 Lecture 9 1 COSC344 Database Theory and Applications Lecture 9 Normalisation COSC344 Lecture 9 1 Overview Last Lecture Functional Dependencies This Lecture Normalisation Introduction 1NF 2NF 3NF BCNF Source: Section

More information

DATABASE NORMALIZATION

DATABASE NORMALIZATION DATABASE NORMALIZATION Normalization: process of efficiently organizing data in the DB. RELATIONS (attributes grouped together) Accurate representation of data, relationships and constraints. Goal: - Eliminate

More information

Normalization of Database

Normalization of Database Normalization of Database UNIT-4 Database Normalisation is a technique of organizing the data in the database. Normalization is a systematic approach of decomposing tables to eliminate data redundancy

More information

Database Design. Marta Jakubowska-Sobczak IT/ADC based on slides prepared by Paula Figueiredo, IT/DB

Database Design. Marta Jakubowska-Sobczak IT/ADC based on slides prepared by Paula Figueiredo, IT/DB Marta Jakubowska-Sobczak IT/ADC based on slides prepared by Paula Figueiredo, IT/DB Outline Database concepts Conceptual Design Logical Design Communicating with the RDBMS 2 Some concepts Database: an

More information

DATABASE DESIGN: NORMALIZATION NOTE & EXERCISES (Up to 3NF)

DATABASE DESIGN: NORMALIZATION NOTE & EXERCISES (Up to 3NF) DATABASE DESIGN: NORMALIZATION NOTE & EXERCISES (Up to 3NF) Tables that contain redundant data can suffer from update anomalies, which can introduce inconsistencies into a database. The rules associated

More information

Normalisation to 3NF. Database Systems Lecture 11 Natasha Alechina

Normalisation to 3NF. Database Systems Lecture 11 Natasha Alechina Normalisation to 3NF Database Systems Lecture 11 Natasha Alechina In This Lecture Normalisation to 3NF Data redundancy Functional dependencies Normal forms First, Second, and Third Normal Forms For more

More information

Fundamentals of Database System

Fundamentals of Database System Fundamentals of Database System Chapter 4 Normalization Fundamentals of Database Systems (Chapter 4) Page 1 Introduction To Normalization In general, the goal of a relational database design is to generate

More information

Unit 3.1. Normalisation 1 - V2.0 1. Normalisation 1. Dr Gordon Russell, Copyright @ Napier University

Unit 3.1. Normalisation 1 - V2.0 1. Normalisation 1. Dr Gordon Russell, Copyright @ Napier University Normalisation 1 Unit 3.1 Normalisation 1 - V2.0 1 Normalisation Overview discuss entity integrity and referential integrity describe functional dependency normalise a relation to first formal form (1NF)

More information

Chapter 9: Normalization

Chapter 9: Normalization Chapter 9: Normalization Part 1: A Simple Example Part 2: Another Example & The Formal Stuff A Problem: Keeping Track of Invoices (cont d) Suppose we have some invoices that we may or may not want to refer

More information

Chapter 6. Database Tables & Normalization. The Need for Normalization. Database Tables & Normalization

Chapter 6. Database Tables & Normalization. The Need for Normalization. Database Tables & Normalization Chapter 6 Database Tables & Normalization Objectives: to learn What normalization is and what role it plays in the database design process About the normal forms 1NF, 2NF, 3NF, BCNF, and 4NF How normal

More information

Normalisation 1. Chapter 4.1 V4.0. Copyright @ Napier University

Normalisation 1. Chapter 4.1 V4.0. Copyright @ Napier University Normalisation 1 Chapter 4.1 V4.0 Copyright @ Napier University Normalisation Overview discuss entity integrity and referential integrity describe functional dependency normalise a relation to first formal

More information

Normalization in Database Design

Normalization in Database Design in Database Design Marek Rychly mrychly@strathmore.edu Strathmore University, @ilabafrica & Brno University of Technology, Faculty of Information Technology Advanced Databases and Enterprise Systems 14

More information

RELATIONAL DATABASE DESIGN

RELATIONAL DATABASE DESIGN RELATIONAL DATABASE DESIGN g Good database design - Avoiding anomalies g Functional Dependencies g Normalization & Decomposition Using Functional Dependencies g 1NF - Atomic Domains and First Normal Form

More information

Normalization in OODB Design

Normalization in OODB Design Normalization in OODB Design Byung S. Lee Graduate Programs in Software University of St. Thomas St. Paul, Minnesota bslee@stthomas.edu Abstract When we design an object-oriented database schema, we need

More information

Part 6. Normalization

Part 6. Normalization Part 6 Normalization Normal Form Overview Universe of All Data Relations (normalized / unnormalized 1st Normal Form 2nd Normal Form 3rd Normal Form Boyce-Codd Normal Form (BCNF) 4th Normal Form 5th Normal

More information

Database Management System

Database Management System UNIT -6 Database Design Informal Design Guidelines for Relation Schemas; Functional Dependencies; Normal Forms Based on Primary Keys; General Definitions of Second and Third Normal Forms; Boyce-Codd Normal

More information

Chapter 15 Basics of Functional Dependencies and Normalization for Relational Databases

Chapter 15 Basics of Functional Dependencies and Normalization for Relational Databases Chapter 15 Basics of Functional Dependencies and Normalization for Relational Databases Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 15 Outline Informal Design Guidelines

More information

Theory of Relational Database Design and Normalization

Theory of Relational Database Design and Normalization Theory of Relational Database Design and Normalization (Based on Chapter 14 and some part of Chapter 15 in Fundamentals of Database Systems by Elmasri and Navathe) 1 Informal Design Guidelines for Relational

More information

DATABASE SYSTEMS. Chapter 7 Normalisation

DATABASE SYSTEMS. Chapter 7 Normalisation DATABASE SYSTEMS DESIGN IMPLEMENTATION AND MANAGEMENT INTERNATIONAL EDITION ROB CORONEL CROCKETT Chapter 7 Normalisation 1 (Rob, Coronel & Crockett 978184480731) In this chapter, you will learn: What normalization

More information

C# Cname Ccity.. P1# Date1 Qnt1 P2# Date2 P9# Date9 1 Codd London.. 1 21.01 20 2 23.01 2 Martin Paris.. 1 26.10 25 3 Deen London.. 2 29.

C# Cname Ccity.. P1# Date1 Qnt1 P2# Date2 P9# Date9 1 Codd London.. 1 21.01 20 2 23.01 2 Martin Paris.. 1 26.10 25 3 Deen London.. 2 29. 4. Normalisation 4.1 Introduction Suppose we are now given the task of designing and creating a database. How do we produce a good design? What relations should we have in the database? What attributes

More information

Design of Relational Database Schemas

Design of Relational Database Schemas Design of Relational Database Schemas T. M. Murali October 27, November 1, 2010 Plan Till Thanksgiving What are the typical problems or anomalies in relational designs? Introduce the idea of decomposing

More information

Theory of Relational Database Design and Normalization

Theory of Relational Database Design and Normalization Theory of Relational Database Design and Normalization (Based on Chapter 14 and some part of Chapter 15 in Fundamentals of Database Systems by Elmasri and Navathe, Ed. 3) 1 Informal Design Guidelines for

More information

Tutorial on Relational Database Design

Tutorial on Relational Database Design Tutorial on Relational Database Design Introduction Relational database was proposed by Edgar Codd (of IBM Research) around 1969. It has since become the dominant database model for commercial applications

More information

DBMS. Normalization. Module Title?

DBMS. Normalization. Module Title? Normalization Database Normalization Database normalization is the process of removing redundant data from your tables in to improve storage efficiency, data integrity (accuracy and consistency), and scalability

More information

Topic 5.1: Database Tables and Normalization

Topic 5.1: Database Tables and Normalization Topic 5.1: Database Tables and Normalization What is Normalization? Normalization is a process for evaluating and correcting table structures to minimize data redundancies, thereby helping to eliminate

More information

Chapter 10. Functional Dependencies and Normalization for Relational Databases. Copyright 2007 Ramez Elmasri and Shamkant B.

Chapter 10. Functional Dependencies and Normalization for Relational Databases. Copyright 2007 Ramez Elmasri and Shamkant B. Chapter 10 Functional Dependencies and Normalization for Relational Databases Copyright 2007 Ramez Elmasri and Shamkant B. Navathe Chapter Outline 1 Informal Design Guidelines for Relational Databases

More information

Functional Dependency and Normalization for Relational Databases

Functional Dependency and Normalization for Relational Databases Functional Dependency and Normalization for Relational Databases Introduction: Relational database design ultimately produces a set of relations. The implicit goals of the design activity are: information

More information

RELATIONAL DATABASE DESIGN Good Database Design Principles

RELATIONAL DATABASE DESIGN Good Database Design Principles Good Database Design Principles 1. no redundancy a field is stored in only one table, unless it happens to be a foreign key replication of foreign keys is permissible, because they allow two tables to

More information

Normalization. Reduces the liklihood of anomolies

Normalization. Reduces the liklihood of anomolies Normalization Normalization Tables are important, but properly designing them is even more important so the DBMS can do its job Normalization the process for evaluating and correcting table structures

More information

Database design 1 The Database Design Process: Before you build the tables and other objects that will make up your system, it is important to take time to design it. A good design is the keystone to creating

More information

Carnegie Mellon Univ. Dept. of Computer Science 15-415 - Database Applications. Overview - detailed. Goal. Faloutsos CMU SCS 15-415

Carnegie Mellon Univ. Dept. of Computer Science 15-415 - Database Applications. Overview - detailed. Goal. Faloutsos CMU SCS 15-415 Faloutsos 15-415 Carnegie Mellon Univ. Dept. of Computer Science 15-415 - Database Applications Lecture #17: Schema Refinement & Normalization - Normal Forms (R&G, ch. 19) Overview - detailed DB design

More information

Chapter 5: FUNCTIONAL DEPENDENCIES AND NORMALIZATION FOR RELATIONAL DATABASES

Chapter 5: FUNCTIONAL DEPENDENCIES AND NORMALIZATION FOR RELATIONAL DATABASES 1 Chapter 5: FUNCTIONAL DEPENDENCIES AND NORMALIZATION FOR RELATIONAL DATABASES INFORMAL DESIGN GUIDELINES FOR RELATION SCHEMAS We discuss four informal measures of quality for relation schema design in

More information

If it's in the 2nd NF and there are no non-key fields that depend on attributes in the table other than the Primary Key.

If it's in the 2nd NF and there are no non-key fields that depend on attributes in the table other than the Primary Key. Normalization First Normal Form (1st NF) The table cells must be of single value. Eliminate repeating groups in individual tables. Create a separate table for each set of related data. Identify each set

More information

Chapter 10 Functional Dependencies and Normalization for Relational Databases

Chapter 10 Functional Dependencies and Normalization for Relational Databases Chapter 10 Functional Dependencies and Normalization for Relational Databases Copyright 2004 Pearson Education, Inc. Chapter Outline 1 Informal Design Guidelines for Relational Databases 1.1Semantics of

More information

Normalization. Normalization. Normalization. Data Redundancy

Normalization. Normalization. Normalization. Data Redundancy Normalization Normalization o Main objective in developing a logical data model for relational database systems is to create an accurate representation of the data, its relationships, and constraints.

More information

DATABASE DESIGN: Normalization Exercises & Answers

DATABASE DESIGN: Normalization Exercises & Answers DATABASE DESIGN: Normalization Exercises & Answers (a) The table shown in Figure 1 is susceptible to update anomalies. Provide examples of insertion, deletion, and modification anomalies. Answers: This

More information

CS 377 Database Systems. Database Design Theory and Normalization. Li Xiong Department of Mathematics and Computer Science Emory University

CS 377 Database Systems. Database Design Theory and Normalization. Li Xiong Department of Mathematics and Computer Science Emory University CS 377 Database Systems Database Design Theory and Normalization Li Xiong Department of Mathematics and Computer Science Emory University 1 Relational database design So far Conceptual database design

More information

Chapter 10. Functional Dependencies and Normalization for Relational Databases

Chapter 10. 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 information

Normalization. Purpose of normalization Data redundancy Update anomalies Functional dependency Process of normalization

Normalization. Purpose of normalization Data redundancy Update anomalies Functional dependency Process of normalization Normalization Purpose of normalization Data redundancy Update anomalies Functional dependency Process of normalization 1 Purpose of Normalization Normalization is a technique for producing a set of suitable

More information

Database Design and Normalization

Database Design and Normalization Database Design and Normalization CPS352: Database Systems Simon Miner Gordon College Last Revised: 9/27/12 Agenda Check-in Functional Dependencies (continued) Design Project E-R Diagram Presentations

More information

Database Design and Normal Forms

Database Design and Normal Forms Database Design and Normal Forms Database Design coming up with a good schema is very important How do we characterize the goodness of a schema? If two or more alternative schemas are available how do

More information

Functional Dependencies and Finding a Minimal Cover

Functional 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 information

The process of database development. Logical model: relational DBMS. Relation

The process of database development. Logical model: relational DBMS. Relation The process of database development Reality (Universe of Discourse) Relational Databases and SQL Basic Concepts The 3rd normal form Structured Query Language (SQL) Conceptual model (e.g. Entity-Relationship

More information

Tutorial 3 The Relational Database Model

Tutorial 3 The Relational Database Model Tutorial 3 The Relational Database Model References: Topic 3 Lecture notes. Rob, P. & Coronel, C. Database Systems: Design, Implementation & Management, 6th Edition, 2004, Chapter 3, Review Questions 1

More information

Module 5: Normalization of database tables

Module 5: Normalization of database tables Module 5: Normalization of database tables Normalization is a process for evaluating and correcting table structures to minimize data redundancies, thereby reducing the likelihood of data anomalies. The

More information

Teaching Database Modeling and Design: Areas of Confusion and Helpful Hints

Teaching Database Modeling and Design: Areas of Confusion and Helpful Hints Journal of Information Technology Education Volume 6, 2007 Teaching Database Modeling and Design: Areas of Confusion and Helpful Hints George C. Philip, Ph. D. College of Business, The University of Wisconsin

More information

CSCI-GA.2433-001 Database Systems Lecture 7: Schema Refinement and Normalization

CSCI-GA.2433-001 Database Systems Lecture 7: Schema Refinement and Normalization CSCI-GA.2433-001 Database Systems Lecture 7: Schema Refinement and Normalization Mohamed Zahran (aka Z) mzahran@cs.nyu.edu http://www.mzahran.com View 1 View 2 View 3 Conceptual Schema At that point we

More information

Functional Dependencies

Functional Dependencies BCNF and 3NF Functional Dependencies Functional dependencies: modeling constraints on attributes stud-id name address course-id session-id classroom instructor Functional dependencies should be obtained

More information

CST221, Dr. Zhen Jiang Normalization & design (see Appendix pages 42-55)

CST221, Dr. Zhen Jiang Normalization & design (see Appendix pages 42-55) CST221, Dr. Zhen Jiang Normalization & design (see Appendix pages 42-55) Normalization is a process for determining what attributes go into what tables. In order to understand this process, we need to

More information

Database Design Basics

Database Design Basics Database Design Basics Table of Contents SOME DATABASE TERMS TO KNOW... 1 WHAT IS GOOD DATABASE DESIGN?... 2 THE DESIGN PROCESS... 2 DETERMINING THE PURPOSE OF YOUR DATABASE... 3 FINDING AND ORGANIZING

More information

The 3 Normal Forms: Copyright Fred Coulson 2007 (last revised February 1, 2009)

The 3 Normal Forms: Copyright Fred Coulson 2007 (last revised February 1, 2009) The 3 Normal Forms: A Tutorial by Fred Coulson Copyright Fred Coulson 2007 (last revised February 1, 2009) This tutorial may be freely copied and distributed, providing appropriate attribution to the author

More information

SAMPLE FINAL EXAMINATION SPRING SESSION 2015

SAMPLE FINAL EXAMINATION SPRING SESSION 2015 SAMPLE FINAL EXAMINATION SPRING SESSION 2015 School of Computing, Engineering and Mathematics Student family name: Student given name/s: Student ID number: Course: Unit Name (In Full): Database Design

More information

Database Design and Normalization

Database Design and Normalization Database Design and Normalization Chapter 10 (Week 11) EE562 Slides and Modified Slides from Database Management Systems, R. Ramakrishnan 1 Computing Closure F + Example: List all FDs with: - a single

More information

Chapter 5: Logical Database Design and the Relational Model Part 2: Normalization. Introduction to Normalization. Normal Forms.

Chapter 5: Logical Database Design and the Relational Model Part 2: Normalization. Introduction to Normalization. Normal Forms. Chapter 5: Logical Database Design and the Relational Model Part 2: Normalization Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B. Prescott, Fred R. McFadden Robert C. Nickerson ISYS

More information

Normalization. CIS 331: Introduction to Database Systems

Normalization. CIS 331: Introduction to Database Systems Normalization CIS 331: Introduction to Database Systems Normalization: Reminder Why do we need to normalize? To avoid redundancy (less storage space needed, and data is consistent) To avoid update/delete

More information

Lecture 2 Normalization

Lecture 2 Normalization MIT 533 ระบบฐานข อม ล 2 Lecture 2 Normalization Walailuk University Lecture 2: Normalization 1 Objectives The purpose of normalization The identification of various types of update anomalies The concept

More information

Normal forms and normalization

Normal forms and normalization Normal forms and normalization An example of normalization using normal forms We assume we have an enterprise that buys products from different supplying companies, and we would like to keep track of our

More information

Examine the structure of the EMPLOYEES table: EMPLOYEE_ID NUMBER Primary Key FIRST_NAME VARCHAR2(25) LAST_NAME VARCHAR2(25)

Examine the structure of the EMPLOYEES table: EMPLOYEE_ID NUMBER Primary Key FIRST_NAME VARCHAR2(25) LAST_NAME VARCHAR2(25) Examine the structure of the EMPLOYEES table: EMPLOYEE_ID NUMBER Primary Key FIRST_NAME VARCHAR2(25) LAST_NAME VARCHAR2(25) Which three statements inserts a row into the table? A. INSERT INTO employees

More information

Physical Database Design and Tuning

Physical Database Design and Tuning Chapter 20 Physical Database Design and Tuning Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley 1. Physical Database Design in Relational Databases (1) Factors that Influence

More information

Chapter 7: Relational Database Design

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 information

1. Physical Database Design in Relational Databases (1)

1. Physical Database Design in Relational Databases (1) Chapter 20 Physical Database Design and Tuning Copyright 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley 1. Physical Database Design in Relational Databases (1) Factors that Influence

More information

Understanding the Database Design Process

Understanding the Database Design Process 67232976x_ch15.qxd 4/1/8 4:3 PM Page 1 15 Understanding the Database Design Process In this chapter, you ll learn the thought processes behind designing a relational database. After this theory-focused

More information

MCQs~Databases~Relational Model and Normalization http://en.wikipedia.org/wiki/database_normalization

MCQs~Databases~Relational Model and Normalization http://en.wikipedia.org/wiki/database_normalization http://en.wikipedia.org/wiki/database_normalization Database normalization is the process of organizing the fields and tables of a relational database to minimize redundancy. Normalization usually involves

More information

- Eliminating redundant data - Ensuring data dependencies makes sense. ie:- data is stored logically

- Eliminating redundant data - Ensuring data dependencies makes sense. ie:- data is stored logically Normalization of databases Database normalization is a technique of organizing the data in the database. Normalization is a systematic approach of decomposing tables to eliminate data redundancy and undesirable

More information

Database Design and the E-R Model

Database Design and the E-R Model C H A P T E R 7 Database Design and the E-R Model Practice Exercises 7.1 Answer: The E-R diagram is shown in Figure 7.1. Payments are modeled as weak entities since they are related to a specific policy.

More information

Inf202 Introduction to Data and Databases (Spring 2011)

Inf202 Introduction to Data and Databases (Spring 2011) Inf202 Introduction to Data and Databases (Spring 2011) Jagdish S. Gangolly Informatics CCI SUNY Albany March 3, 2011 Database Normalisation: An extended example Figure: Un-normalised Database Relation

More information

A. TRUE-FALSE: GROUP 2 PRACTICE EXAMPLES FOR THE REVIEW QUIZ:

A. TRUE-FALSE: GROUP 2 PRACTICE EXAMPLES FOR THE REVIEW QUIZ: GROUP 2 PRACTICE EXAMPLES FOR THE REVIEW QUIZ: Review Quiz will contain very similar question as below. Some questions may even be repeated. The order of the questions are random and are not in order of

More information

Database Normalization. Mohua Sarkar, Ph.D Software Engineer California Pacific Medical Center 415-600-7003 sarkarm@sutterhealth.

Database Normalization. Mohua Sarkar, Ph.D Software Engineer California Pacific Medical Center 415-600-7003 sarkarm@sutterhealth. Database Normalization Mohua Sarkar, Ph.D Software Engineer California Pacific Medical Center 415-600-7003 sarkarm@sutterhealth.org Definition A database is an organized collection of data whose content

More information

C HAPTER 4 INTRODUCTION. Relational Databases FILE VS. DATABASES FILE VS. DATABASES

C HAPTER 4 INTRODUCTION. Relational Databases FILE VS. DATABASES FILE VS. DATABASES INRODUCION C HAPER 4 Relational Databases Questions to be addressed in this chapter: How are s different than file-based legacy systems? Why are s important and what is their advantage? What is the difference

More information

Determination of the normalization level of database schemas through equivalence classes of attributes

Determination of the normalization level of database schemas through equivalence classes of attributes Computer Science Journal of Moldova, vol.17, no.2(50), 2009 Determination of the normalization level of database schemas through equivalence classes of attributes Cotelea Vitalie Abstract In this paper,

More information

Entity - Relationship Modelling

Entity - Relationship Modelling Topic 5 Entity - Relationship Modelling LEARNING OUTCOMES When you have completed this Topic you should be able to: 1. Acquire the basic concepts of the Entity-Relationship (ER) model. 2. Discuss how to

More information

KNOWLEDGE FACTORING USING NORMALIZATION THEORY

KNOWLEDGE FACTORING USING NORMALIZATION THEORY KNOWLEDGE FACTORING USING NORMALIZATION THEORY J. VANTHIENEN M. SNOECK Katholieke Universiteit Leuven Department of Applied Economic Sciences Dekenstraat 2, 3000 Leuven (Belgium) tel. (+32) 16 28 58 09

More information

Physical Design. Meeting the needs of the users is the gold standard against which we measure our success in creating a database.

Physical Design. Meeting the needs of the users is the gold standard against which we measure our success in creating a database. Physical Design Physical Database Design (Defined): Process of producing a description of the implementation of the database on secondary storage; it describes the base relations, file organizations, and

More information

B2.2-R3: INTRODUCTION TO DATABASE MANAGEMENT SYSTEMS

B2.2-R3: INTRODUCTION TO DATABASE MANAGEMENT SYSTEMS B2.2-R3: INTRODUCTION TO DATABASE MANAGEMENT SYSTEMS NOTE: 1. There are TWO PARTS in this Module/Paper. PART ONE contains FOUR questions and PART TWO contains FIVE questions. 2. PART ONE is to be answered

More information

Database Design and Implementation

Database Design and Implementation Database Design and Implementation A practical introduction using Oracle SQL Howard Gould 1 Introduction These slides accompany the book Database Design and Implementation A practical introduction using

More information

Simple Invoicing Desktop Database with MS Access 2013. c 2015 by David W. Gerbing School of Business Administration Portland State University

Simple Invoicing Desktop Database with MS Access 2013. c 2015 by David W. Gerbing School of Business Administration Portland State University Simple Invoicing Desktop Database with MS Access 2013 c 2015 by David W. Gerbing School of Business Administration Portland State University July 2, 2015 CONTENTS 1 Contents 1 Create a New Database 1 2

More information

BCA. Database Management System

BCA. Database Management System BCA IV Sem Database Management System Multiple choice questions 1. A Database Management System (DBMS) is A. Collection of interrelated data B. Collection of programs to access data C. Collection of data

More information

Database Development and Management with SQL

Database Development and Management with SQL Chapter 4 Database Development and Management with SQL Objectives Get started with SQL Create database objects with SQL Manage database objects with SQL Control database object privileges with SQL 4.1

More information

Benefits of Normalisation in a Data Base - Part 1

Benefits of Normalisation in a Data Base - Part 1 Denormalisation (But not hacking it) Denormalisation: Why, What, and How? Rodgers Oracle Performance Tuning Corrigan/Gurry Ch. 5, p69 Stephen Mc Kearney, 2001. 1 Overview Purpose of normalisation Methods

More information

Relational Data Analysis I

Relational Data Analysis I Relational Data Analysis I Relational Data Analysis Prepares Business data for representation using the relational model The relational model is implemented in a number of popular database systems Access

More information

Question 1. Relational Data Model [17 marks] Question 2. SQL and Relational Algebra [31 marks]

Question 1. Relational Data Model [17 marks] Question 2. SQL and Relational Algebra [31 marks] EXAMINATIONS 2005 MID-YEAR COMP 302 Database Systems Time allowed: Instructions: 3 Hours Answer all questions. Make sure that your answers are clear and to the point. Write your answers in the spaces provided.

More information

Normalisation. Royal Museum for Central Africa 5 June 2013. Edward Vanden Berghe

Normalisation. Royal Museum for Central Africa 5 June 2013. Edward Vanden Berghe Normalisation Royal Museum for Central Africa 5 June 2013 Edward Vanden Berghe What is Normalisation? Theoretical: satisfying the requirements of the different Normal Forms, as spelled out by (mainly)

More information

An Introduction to Relational Database Management System

An Introduction to Relational Database Management System History The concept of relational databases was first described by Edgar Frank Codd (almost exclusively referenced as E. F. Codd in technical literature) in the IBM research report RJ599, dated August

More information

DATABASE INTRODUCTION

DATABASE INTRODUCTION Introduction The history of database system research is one of exceptional productivity and startling economic impact. We have learnt that from the days of file-based systems there are better ways to handle

More information

Fundamentals of Database Design

Fundamentals of Database Design Fundamentals of Database Design Zornitsa Zaharieva CERN Data Management Section - Controls Group Accelerators and Beams Department /AB-CO-DM/ 23-FEB-2005 Contents : Introduction to Databases : Main Database

More information

Schema Refinement, Functional Dependencies, Normalization

Schema Refinement, Functional Dependencies, Normalization Schema Refinement, Functional Dependencies, Normalization MSCI 346: Database Systems Güneş Aluç, University of Waterloo Spring 2015 MSCI 346: Database Systems Chapter 19 1 / 42 Outline 1 Introduction Design

More information

Microsoft Access 2010

Microsoft Access 2010 IT Training Microsoft Access 2010 Jane Barrett, IT Training & Engagement Team Information System Services Version 3.0 Scope Learning outcomes Learn how to navigate around Access. Learn how to design and

More information

Modernize your NonStop COBOL Applications with XML Thunder September 29, 2009 Mike Bonham, TIC Software John Russell, Canam Software

Modernize your NonStop COBOL Applications with XML Thunder September 29, 2009 Mike Bonham, TIC Software John Russell, Canam Software Modernize your NonStop COBOL Applications with XML Thunder September 29, 2009 Mike Bonham, TIC Software John Russell, Canam Software Agenda XML Overview XML Thunder overview Case Studies Q & A XML Standard

More information

Access Queries (Office 2003)

Access Queries (Office 2003) Access Queries (Office 2003) Technical Support Services Office of Information Technology, West Virginia University OIT Help Desk 293-4444 x 1 oit.wvu.edu/support/training/classmat/db/ Instructor: Kathy

More information

Files. Files. Files. Files. Files. File Organisation. What s it all about? What s in a file?

Files. Files. Files. Files. Files. File Organisation. What s it all about? What s in a file? Files What s it all about? Information being stored about anything important to the business/individual keeping the files. The simple concepts used in the operation of manual files are often a good guide

More information

Relational Database: Additional Operations on Relations; SQL

Relational Database: Additional Operations on Relations; SQL Relational Database: Additional Operations on Relations; SQL Greg Plaxton Theory in Programming Practice, Fall 2005 Department of Computer Science University of Texas at Austin Overview The course packet

More information

A Short Tutorial on Using Visio 2010 for Entity-Relationship Diagrams

A Short Tutorial on Using Visio 2010 for Entity-Relationship Diagrams A Short Tutorial on Using Visio 2010 for Entity-Relationship Diagrams by Nezar Hussain Microsoft Visio 2010 is a flexible software tool that allows users to create some diagrams and charts, providing an

More information

Normalization. Functional Dependence. Normalization. Normalization. GIS Applications. Spring 2011

Normalization. Functional Dependence. Normalization. Normalization. GIS Applications. Spring 2011 Normalization Normalization Normalization is a foundation for relational database design Systematic approach to efficiently organize data in a database GIS Applications Spring 2011 Objectives Minimize

More information

Exercise 1: Relational Model

Exercise 1: Relational Model Exercise 1: Relational Model 1. Consider the relational database of next relational schema with 3 relations. What are the best possible primary keys in each relation? employ(person_name, street, city)

More information

Notes. Information Systems. Higher Still. Higher. www.hsn.uk.net. HSN31010 Database Systems First Normal Form. Contents

Notes. Information Systems. Higher Still. Higher. www.hsn.uk.net. HSN31010 Database Systems First Normal Form. Contents Higher Information Systems First Normal Form Contents Normalising to First Normal Form 1 What is Normalising? 1 Normal Forms 1 The Process 1 Worked Example 2 Why do we Normalise? 4 These notes were created

More information

CPS352 Database Systems: Design Project

CPS352 Database Systems: Design Project CPS352 Database Systems: Design Project Purpose: Due: To give you experience with designing and implementing a database to model a real domain Various milestones due as shown in the syllabus Requirements

More information

http://www.thedataanalysis.com/sql/sql-programming.html

http://www.thedataanalysis.com/sql/sql-programming.html http://www.thedataanalysis.com/sql/sql-programming.html SQL: UPDATE Statement The UPDATE statement allows you to update a single record or multiple records in a table. The syntax for the UPDATE statement

More information