Seminar 9: OODB Design (Self Study)

Slides:



Advertisements
Similar presentations
Week 5 Relational Database Design by ER- -to-Relational Mapping.
Advertisements

Copyright © 2004 Pearson Education, Inc.. Chapter 3 Data Modeling Using the Entity-Relationship Model.
Dr. Mohamed Osman Hegaz1 Conceptual data base design: The conceptual models: The Entity Relationship Model.
Information storage: Introduction of database 10/7/2004 Xiangming Mu.
Seminar #: 9 (Object Oriented Database Schema in ODL) Advanced Databases (CM036) 1 Seminar 9 : OODB Schema in ODL Purpose To understand how an OODB is.
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.
SQL Structured Query Language Programming Course.
1 Entity-Relationship Diagram. 2 Components of ERD: –Entity –Relationship –Cardinality –Attributes.
Slide Chapter 7 Relational Database Design by ER- to-Relational Mapping.
Logical Design database design. Dr. Mohamed Osman Hegaz2 Conceptual Database Designing –Provides concepts that are close to the way many users perceive.
Seminar 10: OODB Design (Self-Study)
Lecture 03 Entity-Relationship Diagram. Chapter Outline.
Seminar #: 10 (Object Oriented Database Design) Advanced DB Technologies (CG096) 1 Seminar 10 : OODB Design Purpose To understand how an OODB is structured.
Chapter 4 Extended Entity-Relationship (EER)Model Incorporates Set-subset Relationships Incorporates Generalization Hierarchies Constraints: Coverage Constraints:
The ODMG Standard for Object Databases
Seminar #: 10a (Object Oriented Database Design) Advanced Databases (CM036) 1 Seminar 10a : OODB Design Purpose This seminar is the continuation of seminar.
Lecture (8) 1. Relational Database Design by ER- and EERR- to-Relational Mapping 2.
Conceptual Modelling The Entity-Relationship (ER) Model The ER diagram Data Modelling.
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.
ER Diagrams and Relational Model CS 174a (Winter 2015)
Data Modeling Using the Entity- Relationship (ER) Model
COP Introduction to Database Structures
Comp 1100 Entity-Relationship (ER) Model
Data Modeling Using the ERD
Relational Database Design by ER- and ERR-to-Relational Mapping
Relational Database Design by ER- and EER-to- Relational Mapping
Data Modeling Using the Entity- Relationship (ER) Model
Entity- Relationship (ER) Model
Relational Database Design by ER- and EER-to- Relational Mapping
Object-Oriented Analysis and Design
MODELS OF DATABASE AND DATABASE DESIGN
Seminar 10 : OODB Design (Self-Study)
Seminar 6 : OODB Schema in ODL
Relational Database Design by ER- and EER-to-Relational Mapping
Relational Database Design by ER- and EERR-to-Relational Mapping
Relational Database Design by ER-to-Relational Mapping
Outline of the ER Model By S.Saha
Entity-Relationship Modeling
Chapter (9) ER and EER-to-Relational Mapping, and other Relational Languages Objectives How a relational database schema can be created from a conceptual.
9/5/2018.
Appendix D: Network Model
Chapter (9) ER and EER-to-Relational Mapping, and other Relational Languages Objectives How a relational database schema can be created from a conceptual.
بسم الله الرحمن الرحيم.
Conceptual data modeling
11/15/2018.
Entity-Relationship Modeling "Extended"
ISC321 Database Systems I Chapter 10: Object and Object-Relational Databases: Concepts, Models, Languages, and Standards Spring 2015 Dr. Abdullah Almutairi.
Chapter 8: Mapping a Conceptual Design into a Logical Design
Relational Database Design by ER- and EER-to-Relational Mapping
Session 2 Welcome: The seventh learning sequence
The Entity-Relationship Model
ODB Design: Handling Associations and Inheritance in ODL
Relational Database Design by ER- and EER-to-Relational Mapping
Chapter 3: Modeling Data in the Organization
Relational Database Design by ER- and EER-to- Relational Mapping
Relational Database Design by ER- and EERR-to-Relational Mapping
4/11/2019.
Mapping an ERD to a Relational Database
Relational Database Design by ER- and EER-to-Relational Mapping
1. Explain the following concepts of the ER data model:
Chapter (7) ER-to-Relational Mapping, and other Relational Languages
Mapping an ERD to a Relational Database
7/19/2019.
Entity-Relationship Modeling "Extended"
Entity-Relationship Modeling "Extended"
Data Modeling and the Entity-Relationship Model
Relational Database Design by ER-to-Relational Mapping
Presentation transcript:

Seminar 9: OODB Design (Self Study) Purpose To understand how OODB is structured. How a class diagram in UML is mapped onto a generic OO representation. How a relational mapping of a UML class diagram can be compared with an object-oriented representation. Scenario A UML class diagram of a Company database is given in Figure 1, which shows a conceptual model of the database. Company database models the data for a company that has several departments, many employees work for departments on different projects. The database also stores data on employee’s dependents. A mapping of the conceptual model into relational model is given in Figure 2 and a sample relational database shown in Figure 3 (at the end of handout). It is assumed that the students understand UML notations and are familiar with relational concepts. Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Conceptual model for Company database Figure 1 Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Company Relational DB Schema Figure 2 Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Relational Schema Relationships are implemented using foreign keys. See arrows ( ) from foreign keys to the primary keys. Many-to-many relationships are implemented as a linking relation using primary keys of participating relations (see WORKS_ON relation). The real-world concept that an instance of one entity is associated with one or many instances of another entity is not present in relational model. For example, the concept that a department has many employees working for it is not present in the model. The only thing that exist is that an employee has an extra attribute (DNO) that holds the primary key value of his/her department. Multi-valued attributes are implemented as a separate relation (e.g., DEPT_LOCATIONS). Composite attributes (e.g. Name) is implemented in terms of its components (e.g., Fname, Minit, Lname). Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Object Oriented Database Design Fundamental Principles All kinds of relationships are implemented directly using either single valued or multi-valued attributes in both participating entities (classes). Multi-valued attributes are implemented as collection valued attributes (e.g., set, bag, list). Composite attributes are implemented directly (i.e., struct). Primary keys are not required but supported for their usefulness in query processing. Value-based foreign keys are not present ODBs. The data type of attributes can be primitive (e.g., short, float, string, etc) as well as constructed types and collections (e.g., Department, Employee, set<Dependent>, etc). Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Tasks for the Seminar It is assumed that you understand what the UML notations stand for and how they are mapped onto relational model. The UML conceptual model is provided to give you an idea of how the relational model came into existence in the first place. Represent the relational schema in Object Oriented representation. The most important thing to do is thing about the basic concepts of OO databases and try to represent relationships more directly in terms of types, classes, and entities rather than primary or foreign keys. Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)

Sample Company Database (relational) Figure 3 Seminar #: 9 (Object Oriented Database Design) Advanced Databases (CM036)