Entity Relationship Diagram ERD. Background Peter Chen developed ERDs in 1976. Charles Bachman and James Martin have added some slight refinements to.

Slides:



Advertisements
Similar presentations
Chapter # 4 BIS Database Systems
Advertisements

1 The Entity-Relationship Model Chapter 2. 2 Exercise  What can you say about policy of the bank from the ER diagram?  What can you say about the policy.
Ch5: ER Diagrams - Part 1 Much of the material presented in these slides was developed by Dr. Ramon Lawrence at the University of Iowa.
Entity Relationship (ER) Modeling
4 1 Chapter 4 Entity Relationship (ER) Modeling Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 4 Entity Relationship (ER) Modeling.
Chapter 4 Entity Relationship (E-R) Modeling
Entity Relationship (ER) Modeling
IT420: Database Management and Organization
Systems Development Life Cycle
Data Modeling using the Entity-Relationship (ER) Model
Entity-Relation Modeling Hun Myoung Park, Ph.D., Public Management and Policy Analysis Program Graduate School of International Relations International.
Modeling Data The Entity Relationship Model (ER) For Database Design.
Entity-Relationship Model and Diagrams (continued)
Slides adapted from A. Silberschatz et al. Database System Concepts, 5th Ed. Entity-Relationship Model Database Management Systems I Alex Coman, Winter.
Chapter 4 Entity Relationship (ER) Modeling
Database Systems: Design, Implementation, and Management Tenth Edition
Chapter 4 Entity Relationship (E-R) Modeling
Data Modeling 1 Yong Choi School of Business CSUB.
Data Modeling 1 Yong Choi School of Business CSUB.
DeSiamorewww.desiamore.com/ifm1 Database Management Systems (DBMS)  B. Computer Science and BSc IT Year 1.
Chapter 7 Data Modeling with Entity Relationship Diagrams Database Principles: Fundamentals of Design, Implementation, and Management Tenth Edition.
4 1 Chapter 4 Entity Relationship (ER) Modeling Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel.
Database. Basic Definitions Database: A collection of related data. Database Management System (DBMS): A software package/ system to facilitate the creation.
Chapter 5 Entity–Relationship Modeling
BIS 360 – Lecture Six (Part 2) Conceptual Data Modeling (Chapter 10 and partial Chapter 12)
1 ER Modeling BUAD/American University Entity Relationship (ER) Modeling.
Entity-Relationship Model Ch. 3
Principles of Database Design, Part II AIMS 2710 R. Nakatsu.
4 1 Chapter 4 Entity Relationship (ER) Modeling Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
DATABASEMODELSDATABASEMODELS  A database model ◦ defines the logical design of data. ◦ Describes the relationships between different parts of data.
Chapter 2 Data Models Database Systems: Design, Implementation, and Management, Rob and Coronel Adapted for INFS-3200.
Database Design Principles – Lecture 3
Database Systems: Design, Implementation, and Management Eighth Edition Chapter 4 Entity Relationship (ER) Modeling.
Chapter 4 Entity Relationship (ER) Modeling.  ER model forms the basis of an ER diagram  ERD represents conceptual database as viewed by end user 
1 Entity-Relationship Diagram. 2 Components of ERD: –Entity –Relationship –Cardinality –Attributes.
Initial Design of Entity Types for the COMPANY Database Schema Based on the requirements, we can identify four initial entity types in the COMPANY database:
Lecture 4 Conceptual Data Modeling. Objectives Define terms related to entity relationship modeling, including entity, entity instance, attribute, relationship,
DeSiamorePowered by DeSiaMore1 Database Management Systems (DBMS)  B. Computer Science and BSc IT Year 1.
3 & 4 1 Chapters 3 and 4 Drawing ERDs October 16, 2006 Week 3.
Chapter 7 Data Modeling with Entity Relationship Diagrams
Msigwaemhttp//:msigwaem.ueuo.com/1 Database Management Systems (DBMS)  B. Computer Science and BSc IT Year 1.
Data modeling using the entity-relationship model Chapter 3 Objectives How entities, tuples, attributes and relationships among entities are represented.
Database Management Systems MIT Lesson 02 – Database Design (Entity Relationship Diagram) By S. Sabraz Nawaz.
 Entity-relationship models (ERM) Entity-relationship models (ERM)  Simple E-R Diagram Simple E-R Diagram  Weak Entity Weak Entity  Strong Entity.
Database Systems: Design, Implementation, and Management Ninth Edition Chapter 4 Entity Relationship (ER) Modeling.
Databases Illuminated Chapter 3 The Entity Relationship Model.
AL-MAAREFA COLLEGE FOR SCIENCE AND TECHNOLOGY INFO 232: DATABASE SYSTEMS CHAPTER 4 ENTITY RELATIONSHIP (ER) MODELING Instructor Ms. Arwa Binsaleh 1.
INTRODUCTION TO DATABASE DESIGN. Definitions Database Models: Conceptual, Logical, Physical Conceptual: “big picture” overview of data and relationships.
Lesson 4: The Relational Model. Lesson Overview Database Design Entities Relationships E-R Diagrams.
1 Database Systems Entity Relationship (E-R) Modeling.
The Entity-Relationship Model, P. I R. Nakatsu. Data Modeling A data model is the relatively simple representation, usually graphic, of the structure.
Chapter 3: Modeling Data in the Organization. Business Rules Statements that define or constrain some aspect of the business Assert business structure.
EntityRelationshipDiagrams. Entity Relationship Models The E-R (entity-relationship) data model views the real world as a set of basic objects (entities)
1 Information System Analysis Topic-3. 2 Entity Relationship Diagram \ Definition An entity-relationship (ER) diagram is a specialized graphic that illustrates.
©Silberschatz, Korth and Sudarshan2.1Database System Concepts Chapter 2: Entity-Relationship Model Entity Sets Relationship Sets Mapping Constraints Keys.
Department of Mathematics Computer and Information Science1 CS 351: Database Management Systems Christopher I. G. Lanclos Chapter 4.
 DEFINE THE ENTITY  IDENTIFY THE ENTITY TYPES AND SETS OF ENTITY  EXPLAIN THE ATTRIBUTE AND A VALUE SET  EXPLAIN E-R MODEL EXPLAIN THE FOLLOWING RELATIONSHIP.
Rationale Databases are an integral part of an organization. Aspiring Database Developers should be able to efficiently design and implement databases.
The Entity-Relationship Model
Entity Relationship Diagram
TMC2034 Database Concept and Design
Entity Relationship Model
Database Design – Lecture 4
Chapter 4 Entity Relationship (ER) Modeling
Database Systems: Design, Implementation, and Management Tenth Edition
Review of Week 1 Database DBMS File systems vs. database systems
Chapter 4 Entity Relationship (ER) Modeling
Entity-Relationship Diagram (ERD)
Entity Relation Model Tingting Zhang.
Presentation transcript:

Entity Relationship Diagram ERD

Background Peter Chen developed ERDs in Charles Bachman and James Martin have added some slight refinements to the basic ERD principles.

ER Model An entity-relationship model (ERM) is a conceptual way of showing data relationships in software development. ERM is a database modeling technique that generates an abstract diagram or visual representation of a system's data that can be helpful in designing a relational database.

Components of ER model Entity Relationship Attribute

Entity Entities are objects or concepts that represent important data. They are typically nouns, e.g. customer, supervisor, location or promotion. Strong entities exist independently from other entity types. They always possess one or more attributes that uniquely distinguish each occurrence of the entity. E.g. student Weak entities depend on some other entity type. They don't possess unique attributes (also known as a primary key) and have no meaning in the diagram without depending on another entity. E.g. course

Representation in ERD Entities are represented by rectangles.

Attribute Attributes are characteristics of either an entity, a many-to-many relationship, or a one-to-one relationship. Multivalued attributes are those that are capable of taking on more than one value. E.g. phone number Derived attributes are attributes whose value can be calculated from related attribute values. E.g. age Composite attributes are those that can be further subdivided. E.g. name, address

Representation in ERD Attributes are represented by means of ellipses.

Relationship and Cardinality Relationships, which represent the link between different entities. 1.One to one 2.One to many 3.Many to one 4.Many to many Cardinality is the number of instance of an entity from one relation that can be associated with the other relation.

Representation in ERD Relationships are represented by diamond-shaped box. Name of the relationship is written inside the diamond-box. All the entities (rectangles) participating in a relationship, are connected to it by a line.

One to one One-to-one − When only one instance of an entity is associated with the relationship, it is marked as '1:1'. E.g. an EMPLOYEE is assigned one PARKING_PLACE, and each PARKING_PLACE is assigned to one EMPLOYEE

One to many When more than one instance of an entity is associated with a relationship, it is marked as '1:N'. E.g. a PRODUCT_LINE may contain many PRODUCTS, and each PRODUCT belongs to only one PRODUCT_LINE

Many to one When more than one instance of entity is associated with the relationship, it is marked as 'N:1'.

Many to many The following image reflects that more than one instance of an entity on the left and more than one instance of an entity on the right can be associated with the relationship. E.g. a STUDENT may register for more than one COURSE, and each COURSE may have many STUDENTS

Representation I

Representation II

Representation III

Representation IV

How to create an ERD? 1.Identify entities 2.Identify relationships 3.Describe the relationship 4.Add Attributes 5.Complete the diagram

Step 1 The first step in making an ERD is to identify all of the entities you will use. An entity is nothing more than a rectangle with a description of something that your system stores information about. This could be a customer, a manager, an invoice, a schedule, etc. Draw a rectangle for each entity you can think of on your page.

Step 2 Look at two entities, are they related? If so draw a solid line connecting the two entities.

Step 3 How are the entities related? Draw an action diamond between the two entities on the line you just added. In the diamond write a brief description of how they are related.

Step 4 Any key attributes of entities should be added using oval-shaped symbols.

Step 5 Continue to connect the entities with lines, and adding diamonds to describe each relationship until all relationships have been described. Each of your entities may not have any relationships, some may have multiple relationships. That is okay.

Sample ERD

Exercise What can you say about policy of the bank from the ER diagram? What can you say about the policy of the company? balance acct# Account CustAcct name Customer ssn addr deptid budget Dept Manages name Employees ssn lot

EXERCISE Draw the ERD for the following scenarios: A player plays for a team. Each patient has one or more patient histories; each instance of patient history belongs to one patient. An employee may be recorded as having many jobs; a particular job may be recorded as having been held by many employees. A person is a citizen of a country.

Case Study Odeon Cinema and other international cinemas have decided to install a centralized database. This database should keep information regarding cinemas including its name, address and phone number. Each cinema must have one or more theaters and each theater has a specific showing time. During these showing times a movie is shown to the general public

Entities CINEMA THEATER SHOW MOVIE

Relationships A CINEMA must contain one or more THEATERS. A THEATER must belong to one CINEMA only. A THEATER has one or more SHOW times. A particular SHOW time for a movie must belong to one THEATER only A MOVIE can have many SHOW times and a particular SHOW time at a THEATER must belong to one MOVIE only.

Attributes CINEMA Cinema_ID Cinema_Name Cinema_Address Cinema_Phone THEATER Theater_ID Theater_Capacity SHOW Show_Time Show_Date Show_Attendence MOVIE Movie_ID Movie_Title Movie_Director Movie_Rating

ENTITY RELATIONSHIP DIAGRAM

Practice Library Management System School Management System Hospital Management System Bank Management System Transport Management System

ERD Tools RISE Editor ER Studio ERwin Smart Draw Rational Rose Magic Draw