1 CSBP430 – Database Systems Chapter 4: Enhanced Entity– Relationship and Object Modeling Elarbi Badidi College of Information Technology United Arab Emirates.

Slides:



Advertisements
Similar presentations
Prof. Sin-Min Lee Department of Computer Science
Advertisements

© Shamkant B. Navathe CC. © Shamkant B. Navathe CC Chapter 4 - Part I Enhanced Entity-Relationship and UML Modeling Copyright © 2004 Ramez Elmasri and.
Chapter 4: Enhanced Entity-Relationship (EER) Modeling
1 Class Number – CS 304 Class Name - DBMS Instructor – Sanjay Madria Instructor – Sanjay Madria Lesson Title – EER Model –21th June.
Enhanced Entity-Relationship and Object Modeling (Ch 4) Jan R McFadyen1 Class/subclass relationships Inheritance Specialization Generalization.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 4- 1.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 4- 1.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 8 The Enhanced Entity- Relationship (EER) Model.
Enhanced Entity-Relationship and UML Modeling
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 4 Enhanced Entity-Relationship (EER) Modeling.
1 Enhanced Entity Relationship Modelling EER Model Concepts Includes all basic ER modeling concepts Additional concepts: subclasses/superclasses specialization/generalization.
The Enhanced Entity- Relationship (EER) Model
December 4, 2002 Data Modeling – James Cohen Enhanced Entity Relationship (EER) Model Presented by James Cohen.
Chapter 4 The Enhanced Entity-Relationship (EER) Model
© Shamkant B. Navathe CC METU Department of Computer Eng Ceng 302 Introduction to DBMS Enhanced Entity-Relationship (EER) Model by Pinar Senkul resources:
Chapter 41 Enhanced Entity-Relationship and Object Modeling.
EXTENDED-ER (EER) MODEL CONCEPTS. Enhanced-ER (EER) Model Concepts  Basic ER diagram + more concepts =EER model  Additional concepts:  Subclasses/superclasses.
Specialization and generalization
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 4- 1 EER stands for Enhanced ER or Extended ER EER Model Concepts Includes all modeling concepts.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 8 The Enhanced Entity- Relationship (EER) Model.
Enhanced Entity-Relationship and UML Modeling. Enhanced-ER (EER) Model Concepts Includes all modeling concepts of basic ER Additional concepts: subclasses/superclasses,
Enhanced Entity-Relationship Model (EER) 1. Enhanced-ER (EER) Model Concepts Includes all modeling concepts of basic ER Additional concepts: subclasses/superclasses,
Entities and Attributes
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 8 The Enhanced Entry-Relationship (EER) Model.
Chapter 4: The Enhanced ER Model and Business Rules
1 CSE 480: Database Systems Lecture 4: Enhanced Entity-Relationship Modeling Reference: Read Chapter 8.1 – 8.5 of the textbook.
© Shamkant B. Navathe CC. © Shamkant B. Navathe CC Chapter 4 - Part I Enhanced Entity-Relationship and UML Modeling Copyright © 2004 Ramez Elmasri and.
Enhanced Entity – Relationship (EER) and Object Modeling (Based on Chapter 4 in Fundamentals of Database Systems by Elmasri and Navathe, Ed. 4)
THE ENHANCED ER (EER) MODEL CHAPTER 8 (6/E) CHAPTER 4 (5/E)
Database Systems: Enhanced Entity-Relationship Modeling Dr. Taysir Hassan Abdel Hamid.
EER Model.
Enhanced Entity-Relationship (EER) Modeling. Slide 4- 2 Chapter Outline EER stands for Enhanced ER or Extended ER EER Model Concepts Includes all modeling.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 4- 1.
Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Ramez Elmasri and Shamkant Navathe Enhanced-ER (EER) Model Concepts.
Chapter 4 Extended Entity-Relationship (EER)Model Incorporates Set-subset Relationships Incorporates Generalization Hierarchies Constraints: Coverage Constraints:
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 4 Enhanced Entity-Relationship (EER) Modeling.
Exam 1 Review Dr. Bernard Chen Ph.D. University of Central Arkansas.
Slide 4-1 Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Revised by IB & SAM, Fasilkom UI, 2005 Exercise 1. a property or description.
© Shamkant B. Navathe CC Enhanced Entity-Relationship Copyright © 2004 Ramez Elmasri and Shamkant Navathe.
Topic 4 - Part I Enhanced Entity-Relationship and UML Modeling
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe CHAPTER 4 Enhanced Entity-Relationship (EER) Modeling Slide 1- 1.
Lecture 3 A short revision of ER and EER modelling See R. Elmasri, S.B. Navathe. Fundamentals of Database Systems (third edition) Addison-wesley. Chapter.
Enhanced Entity-Relationship and UML Modeling. 2.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 4- 1.
Chapter 4_part2: The Enhanced Entity-Relationship (EER) Model.
Database Systems 主講人 : 陳建源 日期 :99/10/19 研究室 : 法 Chapter 4 Enhanced Entity-Relationship and Object Modeling.
Databases (CS507) CHAPTER 7.
Enhanced Entity-Relationship (EER) Model
The Enhanced Entity- Relationship (EER) Model
Enhanced Entity-Relationship and Object Modeling Objectives
© Shamkant B. Navathe CC.
Conceptual Design & ERD Modelling
Enhanced Entity-Relationship (EER) Modeling
The Enhanced Entity- Relationship (EER) Model
Enhanced Entity-Relationship (EER) Modeling
EER Model – Chapter
Session 2 Welcome: The sixth learning sequence
Enhanced Entity-Relationship (EER) Modeling
© Shamkant B. Navathe CC.
© Shamkant B. Navathe CC.
CS4222 Principles of Database System
Sampath Jayarathna Cal Poly Pomona
ENHANCED ENTITY-RELATIONSHIP (EER) MODEL
Sampath Jayarathna Cal Poly Pomona
© Shamkant B. Navathe CC.
Enhanced Entity-Relationship (EER) Modeling
Enhanced Entity-Relationship (EER) Modeling
Presentation transcript:

1 CSBP430 – Database Systems Chapter 4: Enhanced Entity– Relationship and Object Modeling Elarbi Badidi College of Information Technology United Arab Emirates University

2 In these chapter, you will learn: Subclasses, Superclasses, and Inheritance Specialization and Generalization

3 PROBLEM with ER notation (Chapter 4, pp. 73–89, 93-95) Different databases have become commonplace (engineering manufacturing, multimedia, GIS, database for indexing the WWW, bioinformatics). We (DB designers) need to use additional semantic data modeling concepts to represent these requirements as accurately and clearly as possible. THE ENTITY RELATIONSHIP MODEL IN ITS ORIGINAL FORM DID NOT SUPPORT THE GENERALIZATION ABSTRACTION.

4 Extended Entity-Relationship (EER) Model Incorporates Set-subset relationships Incorporates Generalization Hierarchies NEXT SECTION OF THIS Presentation ILLUSTRATES HOW THE ER MODEL CAN BE EXTENDED WITH Set-subset relationships and Generalization Hierarchies and how we can impose further notation on them.

5 Entity Subclasses, Superclasses, and Inheritance Superclass/subclass, class/subclass relationship The relationship between a superclass and any one of its subclasses. Employee/secretary, employee/technical. Entity that is a member of a subclass inherits all the attributes of the entity. Supertype has shared attributes Subtypes have unique attributes

6 Specialization and Generalization Specialization is the process of defining a set of subclasses of an entity type. Define a set of subclasses of an entity type. Based on job type: secretary, engineer, technician. Based on method of pay: salaried-employee, hourly- employee. Fig 4.1. Car and truck as a specialization of vehicle. Establish additional specific attributes with each subclass. Secretary subclass has an attribute TypingSpeed. Engineer subclass has an attribute EngineerType.

7

8

9 Specialization and Generalization Generalization, reverse process in which defining a generalized entity type from the given entity types. vehicle as a generalization of car and truck. Fig 4.3.

10

11 Constraints on Specialization/Generalization Specialization may consists of multiple subclasses (circle notation) or a single subclass (no circle notation). Disjointness Constraint. Entity must be a member of at most one of the subclasses. It uses (d) notation. Overlap Constraint. Entity may be a member of more than one subclass. It uses (o) notation. Total Specialization. Every entity in the superclass MUST be a member of some subclass. It uses double line notation. Partial Specialization. Entity does not have to belong to any of the subclasses. Employee does not belong to secretary, engineer, technician.

12

13 Specialization/Generalization Hierarchies and Lattices Specialization Hierarchy. A subclass participates as a subclass in only one class/subclass relationship. Specialization Lattice. A subclass can be a subclass in more than one class/subclass relationship. Leaf Node. Class that has no subclass of its own. Shared Subclass. Subclass with more than one superclass (Fig 4.6). Multiple Inheritance Entity inherits attributes and relationships from multiple classes.

14

15 MULTIPLE INHERITANCE In a specialization hierarchy, every subclass has only one superclass. In a specialization lattice, a subclass can have more than one superclass. The subclass is referred to as a shared subclass. A specialization lattice demonstrates multiple inheritance. A shared subclass must satisfy the multiple inheritance intersection constraint, where each instance of the shared subclass is an instance of all of its superclasses.

16 MULTIPLE INHERITANCE EMPLOYEE ENGINEERSECRETARY ENGINEERING MANAGER MANAGER ENGINEERING MANAGER (shared subclass) is a MANGER and an ENGINEER U U U U U

17 Utilizing Specialization and Generalization in Conceptual Data Modeling Top-down Conceptual Refinement Process (Fig 4.7) Bottom-up Conceptual Process.

18

19 Modeling of UNION Types Using Categories Union Type/Category is a class which represent a collection of objects. Single superclass/subclass relationship with more than one superclass, where the superclasses represent different entity types. Use (U) notation. An owner of a vehicle can be a person, a bank, or a company (Fig 4.8).

20 Categories PERSON BANK COMPANY U OWNER The category, OWNER, is a subclass of the union of PERSON, BANK, and COMPANY. OWNER is either a PERSON or a BANK or a COMPANY U

21 Constraints on categorization Total categorization - Every instance of a superclass must be an instance of the category. Partial categorization - An instance of a superclass is not required to be an instance of the category. C = A  B F  (D  E)

22 Example: Partial Categorization of Sponsor

23 Conceptual Object Modeling Using UML Class Diagrams Universal/Unified Modeling Language (UML) is usually used for software design. UML has many diagrams (Class, Composite, Deployment, State, Sequence, Activity, Communication, Use Case, Package). Class diagram is displayed as a box with three sections: class name, attributes, operations. Class diagram is similar to EER.

24 Conceptual Object Modeling Using UML Class Diagrams Component Diagram Deployment Diagram Structure Diagram Class Diagram Sequence Diagram Use Case Diagram

25 Conceptual Object Modeling Using UML Class Diagrams (Fig 4.11) EERUML EntityClass Week EntityQualified association/Qualified aggregation) Composite attributeStructured domain Multivalue attributeSeparate class RelationshipAssociations (min, max)Multiplicities