Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 4 Entity Relationship (ER) Modeling

Similar documents
Database Systems: Design, Implementation, and Management Tenth Edition. Chapter 4 Entity Relationship (ER) Modeling

Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition. Chapter 7 Data Modeling with Entity Relationship Diagrams

Chapter # 4 Entity Relationship (ER) Modeling

Chapter 4. In this chapter, you will learn:

DATABASE SYSTEMS. Chapter 5 Entity Relationship (ER) Modelling DESIGN IMPLEMENTATION AND MANAGEMENT INTERNATIONAL EDITION ROB CORONEL CROCKETT

A l Ain University Of Science and Technology

Relational Model (cont d) & Entity Relational Model. Lecture 2

A l Ain University Of Science and Technology

Non-overlappingoverlapping. Final outcome of the worked example On pages R&C pages R&C page 157 Fig 3.52

Chapter 4 Entity Relationship Modeling In this chapter, you will learn:

The entity is an object of interest to the end user. entity correspond to the table not to a row- in the relational environment.

Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition. Chapter 7 Data Modeling with Entity Relationship Diagrams

LECTURE 3: ENTITY-RELATIONSHIP MODELING

Data Analysis 1. Chapter 2.1 V3.1. Napier University Dr Gordon Russell

David M. Kroenke and David J. Auer Database Processing Fundamentals, Design, and Implementation

Entity Relationship Modelling

Entity Relationship (ER) Modeling

More on the Chen Notation

Entity Relationship Modeling. From Rob and Coronel (2004), Database Systems: Design, Implementation, and Management

Objectives of logical design... Transforming the ERD diagram into relations. Relational database components. Mapping a composite attribute

Discussion Focus. Figure 1

Represent entities and relations with diagrams

1/24/2012. Chapter 7 Outline. Chapter 7 Outline (cont d.) CS 440: Database Management Systems

Using High-Level Conceptual Data Models for Database Design A Sample Database Application Entity Types, Entity Sets, Attributes, and Keys

Conceptual Database Design. COSC 304 Introduction to Database Systems. Entity-Relationship Modeling. Entity-Relationship Modeling

System Analysis And Design Methods ENTITY RELATIONSHIP DIAGRAM (ERD) Prof. Ali Khaleghi Eng. Hadi Haedar

Agenda: Understanding Relationship Types Degree and Cardinality with Examples

The Entity-Relationship Model. The Entity-Relationship model. The ER model. The Entity-Relationship model. E-R Model Constructs. E-R Model Constructs

course 3 Levels of Database Design CSCI 403 Database Management Mines Courses ERD Attributes Entities title 9/26/2018

Entity Relationship Diagram (ERD): Basics

Lecture3: Data Modeling Using the Entity-Relationship Model.

THE ENTITY- RELATIONSHIP (ER) MODEL CHAPTER 7 (6/E) CHAPTER 3 (5/E)

Related download: Instructor Manual for Modern Database Management 12th Edition by Hoffer Venkataraman Topi (Case studies included)

Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition. Chapter 8 Data Modeling Advanced Concepts

IS 263 Database Concepts

Entity-Relationship Model. From Chapter 5, Kroenke book

Multiple Choice Questions

Objectives Definition iti of terms Importance of data modeling Write good names and definitions for entities, relationships, and attributes Distinguis

Essentials of Database Management (Hoffer et al.) Chapter 2 Modeling Data in the Organization

COMP102: Introduction to Databases, 9.1

Database Systems. Overview - important points. Lecture 5. Some introductory information ERD diagrams Normalization Other stuff 08/03/2015

Chapter 12. Entity-Relationship Modeling

Chapter 2 Conceptual Modeling. Objectives

CS 405G: Introduction to Database Systems

COSC 304 Introduction to Database Systems. Entity-Relationship Modeling

System Analysis & design

Advance Database Management System

Information Technology Audit & Cyber Security

Sahaj Computer Solutions. Data Modeling using the Entity Relationship Model

Attributes. Entity-Relationship Model (ERM) IV. Entity Relationship Modeling. Entities and Attributes: Chen and Crow s Foot

DATA MODELING USING THE ENTITY-RELATIONSHIP MODEL. 1 Powered by POeT Solvers Limited

CMP-3440 Database Systems

Chapter 3 Database Modeling and Design II. Database Modeling

Lecture 09. Spring 2018 Borough of Manhattan Community College

Chapter 2: Entity-Relationship Model. Entity Sets. Entity Sets customer and loan. Attributes. Relationship Sets. A database can be modeled as:

Full file at

Entity-Relationship Model

The Entity Relationship Model

Conceptual Database Design (ER modeling) Chapter Three

Intro to DB CHAPTER 6

II. Data Models. Importance of Data Models. Entity Set (and its attributes) Data Modeling and Data Models. Data Model Basic Building Blocks

Database Management System 6 ER Modeling...

Fundamentals of Design, Implementation, and Management Tenth Edition

Conceptual Modeling in ER and UML

Full file at Chapter 2: Foundation Concepts

Lab # 1. Structuring System Requirements: Diagrams

Data Modeling Using the Entity- Relationship Model Design & Analysis of Database Systems

E-R Model. Hi! Here in this lecture we are going to discuss about the E-R Model.

Unified Modeling Language (UML)

Data Modeling During System Analysis. Logical Data Model Stages. What is Conceptual Database Design? Gathering Information for Conceptual

4. Entity Relationship Model

Conceptual Data Modeling and the Entity- Relationship Model. Department of Computer Science Northern Illinois University September 2014

How To Convert An Er Diagram Into Relational Schema Example

Modern Systems Analysis and Design Seventh Edition

L12: ER modeling 5. CS3200 Database design (sp18 s2) 2/22/2018

Data Modeling Using the Entity-Relationship (ER) Model

ER DIAGRAM ER) diagram, a graphical representation of entities and their relationships to each other, typically used in computing in regard to the

Database Management System 5 ER Modeling

Conceptual Data Modeling

Definition. 02. Data Modeling. Example ABC Company Database. Data Modeling Importance

Database Systems ER Model. A.R. Hurson 323 CS Building

Copyright 2016 Ramez Elmasr and Shamkant B. Navathei

Chapter 2 Entity-Relationship Data Modeling: Tools and Techniques. Fundamentals, Design, and Implementation, 9/e

Unit 2 - Data Modeling. Pratian Technologies (India) Pvt. Ltd.

COMP 244. Entity Relationship Model Basics. Entity-Relationship Models. Key elements of the E-R model DATABASE CONCEPTS & APPLICATIONS

MIS2502: Data Analytics Relational Data Modeling - 1. JaeHwuen Jung

Overview of Database Design Process Example Database Application (COMPANY) ER Model Concepts

Elements of the E-R Model

ER Model. Objectives (2/2) Electricite Du Laos (EDL) Dr. Kanda Runapongsa Saikaew, Computer Engineering, KKU 1

Chapter 2 Entity-Relationship Data Modeling: Tools and Techniques. Fundamentals, Design, and Implementation, 9/e

Translation of ER-diagram into Relational Schema. Dr. Sunnie S. Chung CIS430/530

Chapter 6: Entity-Relationship Model

Module 2 : Entity-Relationship Model 15

Introduction to modeling. ER modelling

Chapter 7: Entity-Relationship Model

Ali Khan < Project Name > Design Document. Version 1.0. Group Id: S1. Supervisor Name: Sir.

Review -Chapter 4. Review -Chapter 5


EECS 647: Introduction to Database Systems

A database can be modeled as: + a collection of entities, + a set of relationships among entities.

Transcription:

Database Systems: Design, Implementation, and Management Tenth Edition Chapter 4 Entity Relationship (ER) Modeling

4.1 The Entity Relationship Model (ERM) ER model forms the basis of an ER diagram ERD represents conceptual database as viewed by end user ERDs depict database s main components: Entities Attributes Relationships 2

Entities Refers to entity set and not to single entity occurrence Corresponds to table and not to row in relational environment In Chen and Crow s Foot models, entity is represented by rectangle with entity s name The entity name, a noun, is written in capital letters 3

Attributes Characteristics of entities Chen notation: attributes represented by ovals connected to entity rectangle with a line Each oval contains the name of attribute it represents Crow s Foot notation: attributes written in attribute box below entity rectangle 4

5

Attributes (cont d.) Required attribute: must have a value Optional attribute: may be left empty Domain: set of possible values for an attribute For example, the domain for the grade point average (GPA) attribute is written (0,4) because the lowest possible GPA value is 0 and the highest possible value is 4. Identifiers: one or more attributes that uniquely identify each entity instance Composite identifier: primary key composed of more than one attribute 6

Identifiers (primary keys) Identifiers: one or more attributes that uniquely identify each entity instance Composite identifier: primary key composed of more than one attribute 7

8

9

Attributes (cont d.) Composite attribute can be subdivided Simple attribute cannot be subdivided 10

Attributes (cont d.) Single-value attribute can have only a single value Multivalued attributes can have many values 11

Attributes (cont d.) 12

Attributes (cont d.) M:N relationships and multivalued attributes should not be implemented Create new entity composed of original multivalued attributes components 13

14

Attributes (cont d.) A derived attribute is an attribute whose value is calculated (derived) from other attributes. The derived attribute need not be physically stored within the database; instead, it can be derived by using an algorithm. 15

For example, an employee s age, EMP_AGE, may be found by computing the integer value of the difference between the current date and the EMP_DOB. If you use Microsoft Access, you would use the formula INT((DATE() EMP_DOB)/365). 16

17

Connectivity and Cardinality Connectivity Describes the relationship classification: 1:1 or 1:M or M:N Cardinality Expresses minimum and maximum number of entity occurrences associated with one occurrence of related entity Established by very concise statements known as business rules 18

19

Existence Dependence Existence dependence means that an instance of one entity cannot exist without the existence of some other related entity. Ex: Transactions are existence dependent on accounts. Existence independence Entity can exist apart from one or more related entities 20

Relationship Strength Weak (non-identifying) relationships Exists if PK of related entity does not contain PK component of parent entity Strong (identifying) relationships Exists when PK of related entity contains PK component of parent entity 21

22

23

24

25

Weak Entities Weak entity meets two conditions Existence-dependent Primary key partially or totally derived from parent entity in relationship Database designer determines whether an entity is weak based on business rules 26

Relationship Participation Optional participation One entity occurrence does not require corresponding entity occurrence in particular relationship Mandatory participation One entity occurrence requires corresponding entity occurrence in particular relationship 27

Optional participation For example, in the COURSE generates CLASS relationship, at least some courses do not generate a class. In other words, an entity occurrence (row) in the COURSE table does not necessarily require the existence of a corresponding entity occurrence in the CLASS table. Therefore, the CLASS entity is considered to be optional to the COURSE entity 28

29

Distinction between mandatory or optional 30

1- Class is optional 2- Class is mandatory 31

Relationship Degree Indicates number of entities or participants associated with a relationship Unary relationship Association is maintained within single entity Binary relationship Two entities are associated Ternary relationship Three entities are associated 32

33

34

Recursive Relationships Relationship can exist between occurrences of the same entity set Naturally found within unary relationship 35

Recursive Relationships 1:1 unary relationship may be expressed by an EMPLOYEE may be married to one and only one other EMPLOYEE. 36

Recursive Relationships the 1:M recursive relationship EMPLOYEE manages EMPLOYEE, is implemented in Figure 4.22. 37

Associative (Composite) Entities Also known as bridge entities Used to implement M:N relationships. You should recall from Chapter 3 that the relational model generally requires the use of 1:M relationships. If M:N relationships are encountered, you must create a bridge between the entities that display such relationships. The associative entity is used to implement a M:N relationship between two or more entities. 38

Associative (Composite) Entities This associative entity (also known as a composite or bridge entity) composed of the primary keys of each of the entities to be connected. An example of such a bridge is shown in Figure 4.23. May also contain additional attributes that play no role in connective process 39

40

41

4. 2 Developing an ER Diagram Database design is an iterative process Create detailed narrative of organization s description of operations Identify business rules based on description of operations Identify main entities and relationships from business rules Develop initial ERD Identify attributes and primary keys that adequately describe entities Revise and review ERD 42

43

44

45

46

47

48

initially exist (at the start of the enrollment period) even though no students have enrolled in it, STUDENT is optional to CLASS in the M:N relationship. This M:N relationship must be divided into two 1:M relationships through the use of the ENROLL entity, shown in the ERD segment in Figure 4.31. 49

50

51

52

53

54

Figure 4.37 shows the implementation-ready UML class diagram for Tiny College (note that the ENROLL composite entity is shown in this class diagram. 55