Download presentation
Presentation is loading. Please wait.
1
Entity – Relationship Model
2
Database Design Requirement Analysis Conceptual Design Logical Design
Schema Refinement Physical Design Security Design
3
ER Model Data can be described as Entities Relationships attributes
4
Types of attributes Single attribute Composite attribute
Single – valued attribute Multi – valued attribute Stored attribute Derived attribute Complex attribute
6
Complex Attribute Example - AddressPhone {AddressPhone( {Phone(AreaCode,PhoneNumber)},Address (StreetAddress(Number,Street,ApartmentNumber),City,State,Zip) ) }
7
Entity Set Collection of all entities of the same type. customer
8
Relationship Set
9
Notations in ER Model
10
E-R Diagram Example
11
E-R Diagram Example
12
E-R Diagram Example
13
Degree of a Relationship
Degree- number of participating entity types. Degree = 1 – unary Degree = 2 – binary Degree = 3 – ternary Degree = n – n-ary
14
Example - Unary
15
Example - Binary
16
Example - Ternary
17
Rolename Identifies the exact role in which the entity participates in the relationship.
18
Recursive Relationship
19
Mapping Cardinalities
One to one One to many
20
Mapping Cardinalities
Many to one Many to many
23
ADDITIONAL FEATURES OF THE ER MODEL
Key Constraints
24
Participation Constraints
Total Partial
25
Weak Entities
26
Class Hierarchies Specialization Generalization
30
Aggregation
32
Case Study – Internet Shop
Requirement Analysis I would like my customers to be able to browse my catalog of books and place orders over the Internet. Currently, I take orders over the phone. I have mostly corporate customers who call me and give me the ISBN number of a book and a quantity; they often pay by credit card.
33
Case Study – Internet Shop
I then prepare a shipment that contains the books they ordered. If I don't have enough copies in stock, I order additional copies and delay the shipment until the new copies arrive; I want to ship a customer's entire order together. My catalog includes all the books I sell.
34
Case Study – Internet Shop
For each book, the catalog contains its ISBN number, title, author, purcha.se price, sales price, and the year the book was published. Most of my customers are regulars, and I have records with their names and addresses.
35
Case Study – Internet Shop
Conceptual Design
36
ER Model for the company database
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.