Normalization A337. A337 - Reed Smith2 Structure What is a database? ◦ Tables of information  Rows are referred to as records  Columns are referred.

Slides:



Advertisements
Similar presentations
Chapter 5 Normalization of Database Tables
Advertisements

Database Tables and Normalization
5 5 Normalization of Database Tables Database Systems: Design, Implementation, and Management 4th Edition Peter Rob & Carlos Coronel.
Normalization of Database Tables
Chapter 5 Normalization of Database Tables
Chapter 5 Normalization of Database Tables
Relational Terminology. Normalization A method where data items are grouped together to better accommodate business changes Provides a method for representing.
BTM 382 Database Management Chapter 6: Normalization of Database Tables Chitu Okoli Associate Professor in Business Technology Management John Molson School.
Chapter 5 Normalization of Database Tables
Normalization of Database Tables Special adaptation for INFS-3200
Normalization of Database Tables
Database Design Conceptual –identify important entities and relationships –determine attribute domains and candidate keys –draw the E-R diagram Logical.
Normalization of Database Tables
1 © Prentice Hall, 2002 Chapter 5: Logical Database Design and the Relational Model Modern Database Management 6 th Edition Jeffrey A. Hoffer, Mary B.
4 Chapter 4 Normalization Hachim Haddouti. 4 Hachim Haddouti, CH4, see also Rob & Coronel 2 In this chapter, you will learn: What normalization is and.
Normalization of Database Tables
Normalization of Database Tables
Chapter 5 Normalization of Database Tables
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 5 Normalization of Database Tables.
Terms - data,information, file record, table, row, column, transaction, concurrency Concepts - data integrity, data redundancy, Type of databases – single-user,
Normalization Rules for Database Tables Northern Arizona University College of Business Administration.
Chapter 5 Normalization of Database Tables
Copyright © 2012 Pearson Education, Inc. Publishing as Prentice Hall 9.1.
Week 6 Lecture Normalization
1 Chapter 1 Overview of Database Concepts. 2 Chapter Objectives Identify the purpose of a database management system (DBMS) Distinguish a field from a.
Avoiding Database Anomalies
Database Systems: Design, Implementation, and Management Tenth Edition
RDBMS Concepts/ Session 3 / 1 of 22 Objectives  In this lesson, you will learn to:  Describe data redundancy  Describe the first, second, and third.
5 1 Chapter 5 Normalization of Database Tables Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
Database Systems: Design, Implementation, and Management Ninth Edition Chapter 6 Normalization of Database Tables.
1 DATABASE SYSTEMS DESIGN IMPLEMENTATION AND MANAGEMENT INTERNATIONAL EDITION ROB CORONEL CROCKETT Chapter 7 Normalisation.
Normalization (Codd, 1972) Practical Information For Real World Database Design.
Normalization. We will take a look at –First Normal Form –Second Normal Form –Third Normal Form There are also –Boyce-Codd, Fourth and Fifth normal forms.
BIS Database Systems School of Management, Business Information Systems, Assumption University A.Thanop Somprasong Chapter # 5 Normalization of Database.
資料庫正規化 Database Normalization 取材自 AIS, 6 th edition By Gelinas et al.
Logical Database Design Relational Model. Logical Database Design Logical database design: process of transforming conceptual data model into a logical.
SALINI SUDESH. Primarily a tool to validate and improve a logical design so that it satisfies certain constraints that avoid unnecessary duplication of.
M Taimoor Khan Course Objectives 1) Basic Concepts 2) Tools 3) Database architecture and design 4) Flow of data (DFDs)
In this chapter, you learn about the following: ❑ Anomalies ❑ Dependency and determinants ❑ Normalization ❑ A layman’s method of understanding normalization.
Chapter 7 1 Database Principles Data Normalization Primarily a tool to validate and improve a logical design so that it satisfies certain constraints that.
Normalization Well structured relations and anomalies Normalization First normal form (1NF) Functional dependence Partial functional dependency Second.
Chapter 1Introduction to Oracle9i: SQL1 Chapter 1 Overview of Database Concepts.
Database Design – Lecture 8
Chapter 5 Normalization of Database Tables Database Systems: Design, Implementation, and Management Peter Rob & Carlos Coronel.
Database Principles: Fundamentals of Design, Implementation, and Management Ninth Edition Chapter 6 Normalization of Database Tables Carlos Coronel, Steven.
Normalization of Database Tables
In this session, you will learn to: Describe data redundancy Describe the first, second, and third normal forms Describe the Boyce-Codd Normal Form Appreciate.
A337 - Reed Smith1 Structure What is a database? –Table of information Rows are referred to as records Columns are referred to as fields Record identifier.
Chapter 4 Normalization of Database Tables. 2 Database Tables and Normalization Table is basic building block in database design Table is basic building.
E-R Modeling: Table Normalization. Normalization of DB Tables Normalization ► Process for evaluating and correcting table structures determines the optimal.
Normalization Example. Database Systems, 8 th Edition 2 Database Tables and Normalization Normalization –Process for evaluating and correcting table structures.
Database Systems, 8 th Edition Improving the Design Table structures cleaned up to eliminate initial partial and transitive dependencies Normalization.
Logical Database Design and the Relational Model.
RELATIONAL TABLE NORMALIZATION. Key Concepts Guidelines for Primary Keys Deletion anomaly Update anomaly Insertion anomaly Functional dependency Transitive.
5 1 Normalization of Database Tables. 5 2 Database Tables and Normalization Normalization –Process for evaluating and correcting table structures to minimize.
NORMALIZATION Handout - 4 DBMS. What is Normalization? The process of grouping data elements into tables in a way that simplifies retrieval, reduces data.
5 1 Chapter 5 Normalization of Database Tables Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
Normalizing Database Designs. 2 Objectives In this chapter, students will learn: –What normalization is and what role it plays in the database design.
Normalization.
Chapter 5: Logical Database Design and the Relational Model
Functional Dependencies
Chapter 6 Normalization of Database Tables
Normalization A337.
1st, 2nd, and 3rd Normal Forms
Normalization of Database Tables Uploaded by: mysoftbooks.ml
1st, 2nd, and 3rd Normal Forms
DATABASE DESIGN & DEVELOPMENT
Database Normalization.
Review of Week 3 Relation Transforming ERD into Relations
Presentation transcript:

Normalization A337

A337 - Reed Smith2 Structure What is a database? ◦ Tables of information  Rows are referred to as records  Columns are referred to as fields or attributes  Record identifier is referred to as a record key Types ◦ Relational - Most common, Object-Oriented ◦ Hierarchical, Network (much older types)

A337 - Reed Smith3 Database structure Two approaches to the structure issue: ◦ Conceptual (you start with the question of “what information should I have?”)  ERD from “scratch” ◦ Empirical (you already know what data there will be - you just want to organize it into tables) –  NORMALIZATION

Database Tables and Normalization Normalization - Process for evaluating and correcting table structures to minimize data redundancies ◦ Works through a series of stages called normal forms:  Normal form (1NF)  Second normal form (2NF)  Third normal form (3NF) ◦ There are higher forms but are rarely necessary

A337 - Reed Smith5Normalization Why? ◦ Data structures need to:  Minimize redundancy  Avoid insertion, update, and deletion anomalies How? ◦ Restructure information such that:  Only flat (rectangular) files exist (1st normal form) – No Nulls  All items in each record depend upon) the primary record key (2nd normal form) – No Partial Dependencies  If a field depends upon another then the “other” must be a primary key (3rd normal form) – No Transitive Dependencies

A337 - Reed Smith6 Normalize the following table:

A337 - Reed Smith7 What is wrong with this solution?

First Normal Form Eliminate Nulls/Repeating Groups – ◦ Eliminate repeating groups by eliminating nulls, filling in cells with implied values with actual values Select a primary key ◦ may be a composite key

A337 - Reed Smith9 1NF:

A337 - Reed Smith10 What is wrong with this solution? Partial Dependencies ◦ For example, the sales order number is not relevant in the determination of the item name ◦ Similarly, the customer code and customer name do not depend upon the Item ID, they only depend upon the sales order number.

Second Normal Form Eliminate Partial Dependencies ◦ Write each key component on separate line, and then write the original (composite) key on the last line ◦ Each component will become the key in a new table Identify the Dependent Attributes ◦ Determine which attributes are dependent on which other attributes

Creating 3 Tables SO_Number, Item_Number SO_Number, Item_Number

A337 - Reed Smith13 2NF:

A337 - Reed Smith14 What is wrong with this solution? Transitive Dependencies ◦ Notice that the third column of the Sales Orders file has the Customer name and that depends upon the customer number. ◦ But the customer number is not the primary key

Database Systems: Design, Implementation, & Management, 6 th Edition, Rob & Coronel Third Normal Form 1. For every transitive dependency, write its determinant as a PK for a new table 2. Identify the attributes dependent on each determinant identified in Step 1 and identify the dependency 3. Remove the dependent attributes in transitive relationship(s) from each table that has such a transitive relationship

A337 - Reed Smith16 3NF:

Denormalization Creation of normalized relations is important database design goal Processing requirements should also be a goal If tables decomposed to conform to normalization requirements ◦ Number of database tables expands 17

Denormalization ( continued ) Joining larger number of tables takes additional disk input/output (I/O) operations and processing logic ◦ Reduces system speed Conflicts among design efficiency, information requirements, and processing speed are often resolved through compromises that may include denormalization A337 Database Systems: Design, Implementation, & Management, 6 th Edition, Rob & Coronel 18