IST 318 Database Administration

Slides:



Advertisements
Similar presentations
Entity-Relationship (ER) Modeling
Advertisements

System Analysis - Data Modeling
Data Modeling Entity - Relationship Models. Models Used to represent unstructured problems A model is a representation of reality Logical models  show.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 10 Structuring.
Entity Relationship Modeling Objectives: To illustrate how relationships between entities are defined and refined. To know how relationships are incorporated.
The Relational Database Model
3 The Relational Model MIS 304 Winter Class Objectives That the relational database model takes a logical view of data That the relational model’s.
Computer System Analysis Chapter 10 Structuring System Requirements: Conceptual Data Modeling Dr. Sana’a Wafa Al-Sayegh 1 st quadmaster University of Palestine.
DATABASE MANAGEMENT SYSTEMS BASIC CONCEPTS 1. What is a database? A database is a collection of data which can be used: alone, or alone, or combined /
CSCI 3140 Module 2 – Conceptual Database Design Theodore Chiasson Dalhousie University.
IS 325 Notes for Wednesday September 4, Syllabus Change I eliminated quizzes I increased the points allocated to homework assignments.
Copyright (c) 2014 Pearson Education, Inc. Introduction to Databases.
Concepts and Terminology Introduction to Database.
Conceptual Data Modeling. What Is a Conceptual Data Model? A detailed model that shows the overall structure of organizational data A detailed model.
Unit 3 Conceptual Data Modeling. Key Concepts Conceptual data modeling process Classes and objects Attributes Identifiers, candidate keys, and primary.
DataBase Management System What is DBMS Purpose of DBMS Data Abstraction Data Definition Language Data Manipulation Language Data Models Data Keys Relationships.
Lecture 4 Conceptual Data Modeling. Objectives Define terms related to entity relationship modeling, including entity, entity instance, attribute, relationship,
3 & 4 1 Chapters 3 and 4 Drawing ERDs October 16, 2006 Week 3.
Entity Relationship Diagram (ERD). Objectives Define terms related to entity relationship modeling, including entity, entity instance, attribute, relationship.
CHAPTER 2 : RELATIONAL DATA MODEL Prepared by : nbs.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 10 Structuring.
ERD :: 19 / 1 / Entity-Relationship (ER) Modeling. ER Modeling is a top-down approach to database design. Entity Relationship (ER) Diagram –A.
ENTITY RELATIONSHIP DIAGRAM. Objectives Define terms related to entity relationship modeling, including entity, entity instances, attribute, relationship.
IT 5433 LM3 Relational Data Model. Learning Objectives: List the 5 properties of relations List the properties of a candidate key, primary key and foreign.
C_ITIP211 LECTURER: E.DONDO. Unit 4 : DATA MODELING.
COP Introduction to Database Structures
Entity Relationship Modeling
Chapter 10 Structuring System Requirements: Conceptual Data Modeling
Logical Database Design and the Rational Model
Business System Development
Entity-Relationship Model
Understanding Data Storage
Chapter 6 Structuring System Requirements: Conceptual Data Modeling
DESIGNING DATABASE APPLICATIONS
Tables and Their Characteristics
Database Design – Lecture 4
Database Systems: Design, Implementation, and Management Tenth Edition
Chapter 4 Relational Model Characteristics
Lecture 2 The Relational Model
ERD :: 19 / 1 / Entity-Relationship (ER) Modeling. ER Modeling is a top-down approach to database design. Entity Relationship (ER) Diagram –A.
Translation of ER-diagram into Relational Schema
Entity-Relationship Model and Diagrams (continued)
Chapter 3 The Relational Database Model
ERD’s REVIEW DBS201.
מודל הנתונים.
Entity Relationship Diagrams
Chapter 4 Entity Relationship (ER) Modeling
Chapter 10 Structuring System Requirements: Conceptual Data Modeling
Relational Database Model
IST 318 Database Administration
Database Systems: Design, Implementation, and Management Ninth Edition
Database Systems Instructor Name: Lecture-10.
Entities Things about which you need to store data. One entity for each different thing. At least two attributes At least two occurrences Not a property.
Chapter 3: Modeling Data in the Organization
The Relational Database Model
Database Design Hacettepe University
Database Design: Relational Model
Guide to Modeling Keys to E-R diagrams.
INSTRUCTOR: MRS T.G. ZHOU
IT 244 Database Management System
Chapter 10 Structuring System Requirements: Conceptual Data Modeling
From conceptual to relational data model
Guide to Modeling Keys to E-R diagrams.
ER MODELING Instructor: SAMIA ARSHAD
Chapter # 4 Entity Relationship (ER) Modeling.
Lecture 10 Structuring System Requirements: Conceptual Data Modeling
Chapter 3 The Relational Model
Database Design Chapter 7.
Presentation transcript:

IST 318 Database Administration Lecture 4 Data Modeling

Topics Entities Relationship Attributes and keys Normalization

Data Modeling Data modeling is trying to answer the WHAT questions What data items are needed? What are the relationships between these items? Data modeling is critical in database design Starting from collecting data requirements Providing a conceptual model of entities & relationships essential for communication and understanding A blueprint to build the physical database

Benefits of a Sound Data Model Minimum data redundancy Maximum data integrity Better data sharing Increased consistency More timely access to data: performance Better data usability: overall Additional benefits New usages Data mining  find out patterns hidden in normal data

Three Rules to Follow Don’t think process; think structure Don’t think physical; think conceptual Focus on requirement from business perspective Avoid getting down to details such as storage issues and DBMS constraints Don’t think process; think structure The main point is to answer what need to be stored and what is the right way to represent the interrelationships Not when and how they are used Don’t think navigation; think relationship Focus on compiling the dictionary, don’t worry about in how many different ways it can be used Several constraints have been used for data integrity purposes: Primary key: means not null and unique. Not null: a valid pet_type value is needed for any record. check (pet_sex_flag_mf in (‘M’, ‘F’)): only the two specific values (M and F) are allowed The data type char is selected for pet_sex_flag_mf, since its length is fix to 1.

Entities and Entity Occurrences Entity (also known as entity set) Similar to the concept of class Real-world or conceptual concepts that can be described via a number of attributes A template of entities of the same kind Examples: employee, department, location Entity occurrences (a simple entities) Similar to the concept of object Instances of certain types (or entity sets) Examples: Craig Mullin, Administrative, location #1

Attributes An attribute is a characteristic of an entity An attribute does one of the three things Identifies: uniquely identify a record Candidate key Becomes primary key when chosen Should be immutable Relates: link to an occurrence in another entity Foreign key Describes: depicts or express a characteristic of an entity occurrence The salary attribute of the employee entity

Keys Candidate keys Primary keys Foreign keys Sometimes it’s possible that more than sets of attributes can uniquely identify an occurrence of an entity Example: Both SSN and StudentId in the entity STUDENT (StudentId,LastName,FirstName,SSN, ...) Primary keys The one chosen from a set of candidate keys Foreign keys Identify a relationship between entity occurrences in two entities

Relationships Defines how different entities relate to each other The keys define a relationship: PK-FK Naming Relationships Example: between COURSE and INSTRUCTOR Entities are nouns/noun phrases Relationships are verbs/verb phrases COURSE INSTRUCTOR is-taught-by

Cardinality and Optionality The number of occurrences that can exist between a pair of entities Each end of a relationship has a cardinality Also known as degree Typical cardinality terms: one, many Optionality Whether relationships are mandatory or optional Each end of a relationship has a optionality characteristic

An Example In the employed-by relationship The STORE can have 0, 1, or many EMPLOYEEs If an EXPLOYEE exists, a relationship to a STORE is mandatory EMPLOYEE STORE Employed by

Three Levels Logical data model Physical data model Conceptual data model Depict a high-level, business-oriented view of information Logical data model Offers a comprehensive formal structure that serves as a blueprint for business data Physical data model Transfers the logical data model into a physical implementation using a specific DBMS

Normalization

Normalization – first normal form form eliminates repeating groups and nonatomic data from an entity

Normalization – second normal form Second normal form ensures that all the attributes of each entity are dependent

Normalization – third normal form Third normal form ensures that no relationships between attributes exist within an entity