9
DAVID MORALES Chapter 8

Chapter 8

Embed Size (px)

Citation preview

Page 1: Chapter 8

DAVID MORALES

Chapter 8

Page 2: Chapter 8

Normalization

The process of organizing data in tables in a form that is useable in a data base

Tasks involved in Normalization: Removing repetitive information Making sure each record occupies only one row Determining a piece of data that will uniquely identify

each row Establish how each table’s data relates to other tables

Page 3: Chapter 8

Entity-Relationship Diagram (ERD)

Model that shows logical relationships and interaction among system entities

The Transaction liking the entities, logs hours on, is a third entity with its own characteristics, this entity is called an associative entity

M and N denote the relationship as many to many

Many employees may logs hours on different projects

Time Keeping

Employee ProjectsLogs hours

on

M N

Page 4: Chapter 8

ERD With Cardinality Notation

The marks by the entities represent their cardinality

Cardinality the numeric relationship and shows how instances of one entity relate to instances of another

In the example one employee, or many employees, or none, can log hours on one project, many projects or no projects

Time Keeping

Employee ProjectsLogs hours

on

Page 5: Chapter 8

Tables for Entities in 3NF

Emp. #

Emp. Name

Job-Title Dept. #

Dept. Name

00320 Doe, John Programmer

032 IT

Project #

Project Name

Start Date

Status Total # Hours

1024 I.C.E 10/29/08 Implementation

561

Entry # Date Emp. #

Project #

Hours

1156708 11/7/09

00320 1024 5

Employee

Time Keeping

Projects

Associates records in time keeping with records in Projects

Associates records in time keeping with records in Employee Sum total of all hours in

records in Time Keeping with corresponding the project #

Page 6: Chapter 8

Tasks

Indentify all entitiesCreate an initial ERDAssign all data elements to entitiesVerify all data dictionary entitiesCreate tables in standard notation

Page 7: Chapter 8

Tasks

Remove repeating groups (1NF)Remove fields from a table if not dependant

on Primary key (2NF)Ensure every non-key field depend on the key,

the whole key and nothing but the keyIdentify KeysIdentify table relationships

Page 8: Chapter 8

Concurrent Tasks

Identify all entitiesAssign all data elements to entitiesVerify all data dictionary entities

Page 9: Chapter 8

Sequential Tasks

1. Create an initial ERD2. Create tables3. Identify keys4. 1NF5. 2NF6. 3NF7. Identify table relationships