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

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

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

Entity Relationship Diagram (ERD): Basics

ER-to-Relational Mapping

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

Chapter 4. In this chapter, you will learn:

Database Management System 6 ER Modeling...

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

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

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

Represent entities and relations with diagrams

Advance Database Management System

Chapter 9: Relational DB Design byer/eer to Relational Mapping Relational Database Design Using ER-to- Relational Mapping Mapping EER Model

Agenda: Understanding Relationship Types Degree and Cardinality with Examples

Chapter # 4 Entity Relationship (ER) Modeling

ER to Relational Mapping

Objectives Definition iti of terms List five properties of relations State two properties of candidate keys Define first, second, and third normal for

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

A l Ain University Of Science and Technology

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

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

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

Relational Database Components

MIT Database Management Systems Lesson 03: ER-to-Relational Mapping

Chapter 17. Methodology Logical Database Design for the Relational Model

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

Conceptual Data Modeling Using E-R Models. PM Jat

A l Ain University Of Science and Technology

Relational DB Design by ER- and EER-to-Relational Mapping Design & Analysis of Database Systems

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

Chapter 7 Relational Database Design by ER- and EERR-to-Relational Mapping

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

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

Entity-Relationship Model. From Chapter 5, Kroenke book

Chapter 3 Database Modeling and Design II. Database Modeling

Topic 5: Mapping of EER Diagrams to Relations

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

Chapter 12. Entity-Relationship Modeling

Entity Relationship Modelling

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

Database Design and the E-R Model (7.4, )

Fundamentals, Design, and Implementation, 9/e Copyright 2004 Database Processing: Fundamentals, Design, and Implementation, 9/e by David M.

CMP-3440 Database Systems

4. Entity Relationship Model

LECTURE 3: ENTITY-RELATIONSHIP MODELING

Lecture3: Data Modeling Using the Entity-Relationship Model.

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

COMP102: Introduction to Databases, 9.1

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

Multiple Choice Questions

2. DatabaseDesign. Master I Software Engineering. Dr. Imed Bouchrika Dept of Mathematics & Computer Science University of Souk-Ahras

CS403- Database Management Systems Solved Objective Midterm Papers For Preparation of Midterm Exam

Data about data is database Select correct option: True False Partially True None of the Above

LECTURE 6: GUIDELINES FOR GOOD RELATIONAL DESIGN MAPPING ERD TO RELATIONS

COSC344 Database Theory and Applications. σ a= c (P) S. Lecture 4 Relational algebra. π A, P X Q. COSC344 Lecture 4 1

Conceptual Database Design (ER modeling) Chapter Three

The Entity Relationship Model

Lecture4: Guidelines for good relational design Mapping ERD to Relation. Ref. Chapter3

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

Database Management

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

1. Considering functional dependency, one in which removal from some attributes must affect dependency is called

Elements of the E-R Model

Data Modeling Online Training

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

Data Modeling Using the Entity-Relationship (ER) Model

Basant Group of Institution

Database Management Systems LECTURE NOTES 2

Mahathma Gandhi University

Distributed Database Systems By Syed Bakhtawar Shah Abid Lecturer in Computer Science

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

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

The DBMS accepts requests for data from the application program and instructs the operating system to transfer the appropriate data.

Relational Database Systems Part 01. Karine Reis Ferreira

Translating an ER Diagram to a Relational Schema

High Level Database Models

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

Chapter 2 Conceptual Modeling. Objectives

Overview of db design Requirement analysis Data to be stored Applications to be built Operations (most frequent) subject to performance requirement

IS 263 Database Concepts

CS403- Database Management Systems Solved MCQS From Midterm Papers. CS403- Database Management Systems MIDTERM EXAMINATION - Spring 2010

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

Conceptual Modeling in ER and UML

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

Outline. Note 1. CSIE30600 Database Systems ER/EER to Relational Mapping 2

Ch 9: Mapping EER to Relational. Follow a seven-step algorithm to convert the basic ER model constructs into relations steps 1-7

CS/B.Tech/CSE/New/SEM-6/CS-601/2013 DATABASE MANAGEMENENT SYSTEM. Time Allotted : 3 Hours Full Marks : 70

Chapter 1 SQL and Data

SWEN-220 Mathematical Models of Software. Conceptual to Relational Mapping


More on the Chen Notation

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

Entity-Relationship Models 2. Connolly/Begg Chapter 11

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

Modern Systems Analysis and Design

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

Institute of Southern Punjab, Multan

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

SOLUTIONS TO REVIEW QUESTIONS AND EXERCISES FOR PART 3 - DATABASE ANALYSIS AND DESIGN (CHAPTERS 10 15)

Transcription:

Logical database design and the relational model Objectives of logical design... Translate the conceptual design into a logical database design that can be implemented on a chosen DBMS Input: conceptual model (ERD) Output: relational schema, normalized relations Relational database components Data structure Data organized into tables Data manipulation Add, delete, modify, and retrieve using SQL Data integrity Maintained using business rules Transforming the ERD diagram into relations The steps: Map regular entities Map weak entities Map binary relationships Map associative entities Map unary relationships Map ternary relationships Mapping regular entities to relations. Identify the primary key Composite attributes: use only their simple, component attributes Multi-valued attributes: become a separate relation with a foreign key taken from the superior entity Mapping a composite attribute 1

relational schema notation Mapping weak entities Becomes a separate relation with a foreign key taken from the superior entity. The primary key is a combination of the parent identifier and the weak entity identifier. Example of mapping a weak entity Mapping binary relationships One-to-many - primary key on the one side becomes a foreign key on the many side Many-to-many - create a new relation (associative entity) with the primary keys of the two entities as its primary key One-to-one - primary key on the mandatory side becomes a foreign key on the optional side 2

Example of mapping a 1:M relationship Example of mapping an M:M relationship Mapping a binary 1:1 relationship 3

Mapping associative entities Identifier not assigned Default primary key for the association relation is the primary keys of the two entities Identifier assigned It is natural and familiar to endusers Default identifier may not be unique Mapping an associative entity with an identifier Example Mapping unary relationships One-to-many - A foreign key attribute is added within the same relation that references the primary key values (this foreign key must have the same domain as the primary key) A recursive foreign key is a foreign key in a relation that references the primary key values of that same relation EmpNo EmpName EmpAdress Employee Supervises 4

Would look like... Unary Many-to-many Here two relations are created, one to represent the entity type in the relationship and another representing the M:N relationship itself The primary key of the associative relation consists of two attributes, both taking their values from the primary key of the other relation Any non-key attribute of the relationship is included in the associative relation Example Would look like... (b) ITEM and COMPONENT relations (a) Bill-of-materials relationships (M:N) Mapping ternary (and n-ary) relationships convert a ternary relationship to an associative entity in order to represent participation constraints more accurately. Firstly, we create a new associative relation. The default primary key of this relation consists of the three primary key attributes for the participating entities Mapping ternary (and n- ary) relationships These attributes then act in the role of foreign keys that reference the individual primary keys of the participating entity types. Any attributes of the associative entity type become attributes of the new relation 5

Mapping a ternary relationship relational schema notation Questions 6