Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER-to- Relational Mapping.

Slides:



Advertisements
Similar presentations
3/25/2017.
Advertisements

Relational Database Design Via ER Modelling
Mapping ER to Relational Model
1 Class Number – CS 304 Class Name - DBMS Instructor – Sanjay Madria Instructor – Sanjay Madria Lesson Title – EER Model –21th June.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 1- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 2- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 4- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 7- 1.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 7- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 4 Enhanced Entity- Relationship and UML Modeling.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 7 Relational Database Design by ER- and EER-to-Relational Mapping.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 7 Relational Database Design by ER- Mapping.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER-to- Relational Mapping.
Database Systems Chapter 7 ITM 354. Chapter Outline ER-to-Relational Schema Mapping Algorithm –Step 1: Mapping of Regular Entity Types –Step 2: Mapping.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER-to- Relational Mapping.
Summary of Mapping constructs and constraints
Chapter 7 Relational Database Design by ER- and EER-to-Relational Mapping Copyright © 2004 Pearson Education, Inc.
Database Systems ER and EER to Relational Mapping Toqir Ahmad Rana Database Management Systems 1 Lecture 18.
Dr. Bernard Chen Ph.D. University of Central Arkansas
Chapter 91 ER & EER to Relational Mapping. Chapter 92 ER to Relational Mapping Step 1: For each regular entity type E in the ER schema, create a relation.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER-to-Relational Mapping.
Dr. Dang Tran Khanh M.eng. Tran Minh Quang
ER- and EER-to-Relational Mapping
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 7- 1.
Dr. Bernard Chen Ph.D. University of Central Arkansas Fall 2008
Relational Database Design by ER- and EER-to-Relational Mapping
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 7 Relational Database Design by ER- to-Relational Mapping.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Chapter 7 Relational Database Design by ER- Mapping.
Relational Database Design by ER- and EER-to- Relational Mapping
METU Department of Computer Eng Ceng 302 Introduction to DBMS Relational Database Design by ER to Relational Mapping by Pinar Senkul resources: mostly.
Relational Database Design by ER- and EERR-to-Relational Mapping.
Chapter 6 Relational Database Design by ER- and EERR-to-Relational Mapping Copyright © 2004 Pearson Education, Inc.
Relational Database Design by ER- and EER-to-Relational Mapping The main reference of this presentation is the textbook and PPT from : Elmasri & Navathe,
Chapter 5 ER-to- Relational Mapping HUANG XUEHUA.
DatabaseIM ISU1 Chapter 7 ER- and EER-to-Relational Mapping Fundamentals of Database Systems.
ER-TO-RELATIONAL MODEL MAPPING CONTENT SOURCES: ELAMSARI AND NAVATHE, FUNDAMENTALS OF DATABASE MANAGEMENT SYSTEMS.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe CHAPTER 9 Relational Database Design by ER- and EERR-to-Relational Mapping Slide 9- 1.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 7- 1.
Introduction to Database Systems
Relational Database Design by ER- and EER-to-Relational Mapping
Relational Database Design by ER- and EER-to-Relational Mapping
Chapter 7 Relational Database Design by ER- and EERR-to-Relational Mapping.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER- to-Relational Mapping.
Databases (CS507) CHAPTER 8
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 7 Lecture # 17 July 28,2012 Data Modeling using the Entity Relationship.
Relational Database Design by ER- and EER-to-Relational Mapping
Chapter 7 Relational Database Design by ER- and EERR-to-Relational Mapping Copyright © 2004 Pearson Education, Inc.
Chapter 7 Relational Database Design by ER- and EERR-to-Relational Mapping Copyright © 2004 Pearson Education, Inc.
Lecture # 21 Chapter # 7 Relational Database Design by ER- and EER-to-Relational Mapping Muhammad Emran Database Systems.
Relational Database Design by ER- and ERR-to-Relational Mapping
Relational Database Design by ER- and EER-to- Relational Mapping
Relational Database Design by ER- and EER-to-Relational Mapping
ER- and EER-to-Relational
9/5/2018.
11/15/2018.
Chapter 8: Mapping a Conceptual Design into a Logical Design
Relational Database Design by ER- and EER-to-Relational Mapping
Relational Database Design by ER- and EER-to-Relational Mapping
Relational Database Design by ER- and EER-to- Relational Mapping
Relational Database Design by ER- and EERR-to-Relational Mapping
4/11/2019.
Relational Database Design by ER- and EER-to-Relational Mapping
7/19/2019.
Relational Database Design by ER-to-Relational Mapping
Presentation transcript:

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 9 Relational Database Design by ER- and EER-to- Relational Mapping Lecture # 20 August 4,2012

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Review of ER-to-Relational Mapping Algorithm We present the concepts of a general mapping algorithm Algorithm has 7 steps: –Step 1: Mapping of regular (strong) entity types –Step 2: Mapping of weak (dependent) entity types –Steps 3, 4, 5: Mapping of binary relationship types of different cardinality ratios (1:1, 1:N, M:N) –Step 6: Mapping of multi-valued attributes –Step 7: Mapping of n-ary relationship types, n > 2 Example: We use the COMPANY ER schema diagram (Figure 9.1, next slide) to illustrate the mapping steps Additional steps (Steps 8, 9) for mapping EER model constructs (specialization/generalization, UNION types) presented later

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley

EER To Relational Mappings Mapping of Specialization or Generalization Step 8: Options for Mapping Specialization or Generalization.  Option 8A: Multiple relations—superclass and subclasses.  Option 8B: Multiple relations—subclass relations only.  Option 8C: Single relation with one type attribute.  Option 8D: Single relation with multiple type attributes.

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER To Relational Mappings Mapping of Specialization or Generalization Step 8: Options for Mapping Specialization or Generalization.  Option 8A: Suitable for Total, Partial Disjoint or Overlapping  Option 8B: Recommended only for disjoint  Option 8C: Works only for disjoint  Option 8D:Works for specializations whose subclasses are overlapping.

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER To Relational Mappings Mapping of Specialization or Generalization Step 8: Options for Mapping Specialization or Generalization.  Options 8A and 8B can be called the multiple-relation options.  8C and 8D can be called the single-relation options

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER Model Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER Model Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER Model Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Another Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley EER To Relational Mappings Mapping of Union Types Step 9: Mapping of Union Types (Categories). For mapping a category whose defining super classes have different keys, it is customary to specify a new key attribute, called a surrogate key, when creating a relation to correspond to the category.

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Union Type-Example

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley In-Class Exercises Apply the ER-to-Relational Mapping Algorithm to the SHIP_TRACKING ER Schema in Figure 9.8 (next slide)

Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley