Daniel AdinugrohoDatabase Programming 1 DATABASE PROGRAMMING Lecture on 04 – 05 – 2005.

Slides:



Advertisements
Similar presentations
FEN Introduction to the database field: Quality checking table design: Design Guidelines Normalisation Seminar: Introduction to relational.
Advertisements

Relational Terminology. Normalization A method where data items are grouped together to better accommodate business changes Provides a method for representing.
Normalization What is it?
Normalisation Ensuring data integrity in database design 1.
Logical Data Modeling Review Lecture for University of Agder, Grimstad DAT202 Databaser (5.5.11) Judith Molka-Danielsen
Chapter 8 Normal Forms Based on Functional Dependencies Deborah Costa Oct 18, 2007.
Fundamentals, Design, and Implementation, 9/e Chapter 4 The Relational Model and Normalization.
Database Design Conceptual –identify important entities and relationships –determine attribute domains and candidate keys –draw the E-R diagram Logical.
1 NORMALISATION. 2 Introduction Overview Objectives Intro. to Subject Why we normalise 1, 2 & 3 NF Normalisation Process Example Summary.
Normalization of Database Tables
Project and Data Management Software
Normalization A337. A337 - Reed Smith2 Structure What is a database? ◦ Tables of information  Rows are referred to as records  Columns are referred.
Terms - data,information, file record, table, row, column, transaction, concurrency Concepts - data integrity, data redundancy, Type of databases – single-user,
Normalization Quiz Tao Li Grant Horntvedt. 1. Which of the following statements is true: a. Normal forms can be derived by inspecting the data in various.
Chapter 3 The Relational Model and Normalization
Normalization.
Daniel AdinugrohoDatabase Programming 1 DATABASE PROGRAMMING Lecture on 29 – 04 – 2005.
Week 6 Lecture Normalization
Modelling Techniques - Normalisation Description and exemplification of normalisation.Description and exemplification of normalisation. Creation of un-normalised.
CREATE THE DIFFERENCE Normalisation (special thanks to Janet Francis for this presentation)
SQL Normalization Database Design Lecture 5. Copyright 2006Page 2 SQL Normalization Database Design 1 st Normal Form 1 st Normal Form 2 nd Normal Form.
Relational databases and third normal form As always click on speaker notes under view when executing to get more information!
Fundamentals, Design, and Implementation, 9/e. Database Processing: Fundamentals, Design and Implementation, 9/e by David M. KroenkeChapter 4/2 Copyright.
Avoiding Database Anomalies
Normalization A technique that organizes data attributes (or fields) such that they are grouped to form stable, flexible and adaptive entities.
Chapter 4 The Relational Model and Normalization.
The Relational Model and Normalization R. Nakatsu.
Normalization (Codd, 1972) Practical Information For Real World Database Design.
BIS Database Systems School of Management, Business Information Systems, Assumption University A.Thanop Somprasong Chapter # 5 Normalization of Database.
Database Design (Normalizations) DCO11310 Database Systems and Design By Rose Chang.
Database Normalization Lynne Weldon July 17, 2000.
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.
1 Normalization Normalization intro Normalization intro First normal form (1NF) First normal form (1NF) Second normal form (2NF) Second normal form (2NF)
CORE 2: Information systems and Databases NORMALISING DATABASES.
MS Access: Creating Relational Databases Instructor: Vicki Weidler Assistant: Joaquin Obieta.
FEN Quality checking table design: Design Guidelines Normalisation Table Design Is this OK?
Customer Order Order Number Date Cust ID Last Name First Name State Amount Tax Rate Product 1 ID Product 1 Description Product 1 Quantity Product 2 ID.
By Abdul Rashid Ahmad. E.F. Codd proposed three normal forms: The first, second, and third normal forms 1NF, 2NF and 3NF are based on the functional dependencies.
Rules of Database Normalization
Normalization of Database Tables
Methodology – Monitoring and Tuning the Operational System.
©NIIT Normalizing and Denormalizing Data Lesson 2B / Slide 1 of 18 Objectives In this section, you will learn to: Describe the Top-down and Bottom-up approach.
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.
Normalizing Your Database CPT 242. Normalization The procedure where the developer analyzes the data and establishes the table structure to create the.
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.
Database Processing: Fundamentals, Design and Implementation, 9/e by David M. KroenkeChapter 4/1 Copyright © 2004 Please……. No Food Or Drink in the class.
Database Systems, 8 th Edition Improving the Design Table structures cleaned up to eliminate initial partial and transitive dependencies Normalization.
Data modeling Process. Copyright © CIST 2 Definition What is data modeling? –Identify the real world data that must be stored on the database –Design.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 7 Normalization Hour1,2 Presented & Modified by Mahmoud Rafeek Alfarra.
IST 220 – Intro to DB Lecture 4 Database Design thru ER Modeling.
1 CS 430 Database Theory Winter 2005 Lecture 7: Designing a Database Logical Level.
Microsoft Access 2010 Chapter 11 Database Design.
NormalisationNormalisation Normalization is the technique of organizing data elements into records. Normalization is the technique of organizing data elements.
Normalization ACSC 425 Database Management Systems.
IMS 4212: Normalization 1 Dr. Lawrence West, Management Dept., University of Central Florida Normalization—Topics Functional Dependency.
Databases Introduction - concepts. Concepts of Relational Databases.
NORMALIZATION Handout - 4 DBMS. What is Normalization? The process of grouping data elements into tables in a way that simplifies retrieval, reduces data.
SLIDE 1IS 257 – Fall 2006 Normalization Normalization theory is based on the observation that relations with certain properties are more effective.
What Is Normalization  In relational database design, the process of organizing data to minimize redundancy  Usually involves dividing a database into.
Lecture # 17 Chapter # 10 Normalization Database Systems.
Starter Draw a mind map for topic 6 Databases. Objectives Revise topic CG3.6 Databases using various activities and ensure that topics covered are understood.
1 Normalization David J. Stucki. Outline Informal Design Guidelines Normal Forms  1NF  2NF  3NF  BCNF  4NF 2.
Normalization A337.
1st, 2nd, and 3rd Normal Forms
1st, 2nd, and 3rd Normal Forms
Logical Data Modeling – Normalization
Database Normalization.
Presentation transcript:

Daniel AdinugrohoDatabase Programming 1 DATABASE PROGRAMMING Lecture on 04 – 05 – 2005

Daniel AdinugrohoDatabase Programming 2 PREVIOUS LECTURE 1. Introduction to Database Design - 6 Steps Database Design 2. Normalization. - 1NF, 2NF and 3NF and example of normalization. - BCNF, 4NF and 5NF

Daniel AdinugrohoDatabase Programming 3 NEWS 1. All lecture materials are available on 2. Next Lecture will be QUIZ (06/05/2005) - About Normalization - OPEN BOOK - DO NOT CHEAT!!!!!!!!!! or You will get 0. - Exercise for exam, as the question is a typical exam questions, - OK?

Daniel AdinugrohoDatabase Programming 4 REVIEW OF NORMAL FORMS 1NF -> eliminate repeating attributes 1. Identify repeating attributes. 2. All the key attributes are defined. 3. All attributes are dependent on the primary key. 2NF 1. It's in first normal form (1NF) 2. It includes no partial dependencies (where an attribute is dependent on only a part of a primary key). 3NF 1. It's in second normal form (2NF) 2. It contains no transitive dependencies (where a non-key attribute is dependent on another non-key attribute

Daniel AdinugrohoDatabase Programming 5

Daniel AdinugrohoDatabase Programming 6 1 st NORMAL FORM

Daniel AdinugrohoDatabase Programming 7 2 nd NORMAL FORM Employee Table

Daniel AdinugrohoDatabase Programming 8 2 nd NORMAL FORM Project TableEmployee Project Table

Daniel AdinugrohoDatabase Programming 9 3 rd NORMAL FORM Employee TableRate Table

Daniel AdinugrohoDatabase Programming 10 3 rd NORMAL FORM Project TableEmployee Project Table

Daniel AdinugrohoDatabase Programming 11 DENORMALIZATION Normalization is: ● Storing one fact in one place ● Storing related facts about single entity together ● every column of each entity refers non-transitively to only the unique identifier for that entity. Denormalization: is the reversal process of Normalization, which is a process to store a fact in numerous places.

Daniel AdinugrohoDatabase Programming 12 DENORMALIZATION(2) Sometimes we need to do denormalization to accomplish quick retrieval capability for data stored in relational database. Of course we should (whenever possible) normalize our design to provide optimum environment. However, in real world, denormalization is necessary. Some issues need to be considered before denormalization: ● can the system achieve acceptable performance without denormalizating? ● will the performance of the system after denormalizating still unacceptable? ● will the system be less reliable due to denormalization? If there is one 'yes' answer, we should avoid denormalization!

Daniel AdinugrohoDatabase Programming 13 DENORMALIZATION (EXAMPLE) In order to justify denormalization we need to have a business reason for the alteration form 3rd NF. This example design is for a mail order company that has 120,000,000 customers to whom they must send catalogs. The top design is in 3rd normal form because the attributes for State, City, and Country are codependent on the PostalCode field. To fix that we created the PostalCode entity and related it back to the Customer records on the PostalCode foreign key in the Customer table. However, during system testing it was discovered that the time required to produce 120,000,000 mailing labels through a two-table join was much longer than if the labels could be produced from a single table. The table was then denormalized by reintroducing the City, State, and Country attributes to the Customer table. After doing this it would be heavily documented including the normal form that is violated, the reason for the violation, and the consequences of the violation. Any violation of a fully normalized design carries with it potential problems in the area of updates.

Daniel AdinugrohoDatabase Programming 14 REFERENCES ● Craig, S. Mullin, Denormalization, zation/CraigMullinsGuidelines/i001fe02.htm ● Ian Gilfillan, Database Normalization, ● Mike Hillyer, An Introduction to Database Normalization, ● David Faour, Database Normalization,