0% found this document useful (0 votes)
50 views

Database Theoretic Basis

The document discusses Entity Relationship (ER) modeling and developing ER diagrams. It provides examples of entities like students and courses, and relationships like enrollment. Key aspects of ER modeling are that it helps document a system's information requirements and involves creating entity sets, relationship sets, and attributes on an ER diagram. The diagram uses graphical symbols like rectangles for entities and diamonds for relationships. The ER model originated in a seminal 1976 paper by Peter Chen and has been highly influential in database design.

Uploaded by

Joel Fj Muskwe
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
50 views

Database Theoretic Basis

The document discusses Entity Relationship (ER) modeling and developing ER diagrams. It provides examples of entities like students and courses, and relationships like enrollment. Key aspects of ER modeling are that it helps document a system's information requirements and involves creating entity sets, relationship sets, and attributes on an ER diagram. The diagram uses graphical symbols like rectangles for entities and diamonds for relationships. The ER model originated in a seminal 1976 paper by Peter Chen and has been highly influential in database design.

Uploaded by

Joel Fj Muskwe
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPT, PDF, TXT or read online on Scribd
You are on page 1/ 15

Database Theoretic Basis

Entity Relationship (E-R) Modeling

Developing an E-R Diagram


The process of database design is an iterative rather than a linear or sequential process. It usually begins with a general narrative of the organizations operations and procedures. The basic E-R model is graphically depicted and presented for review. The process is repeated until the end users and designers agree that the E-R diagram is a fair representation of the organizations activities and functions.

works for

department
1 1

employee
supervisee supervisor

manages
N M

controls
N

supervision

works on

project

dependents of
N

dependent

partial constraint total constraint


3

ER Modeling
Entity Relationship Modeling is a process used to help us understand and document the informational requirements of a system. - a system at your university, college, or school needs to keep information about students including their names, addresses, birth dates, courses, enrollments, grades, etc. - these things are documented in the model - we create a drawing called an Entity Relationship Diagram, or ERD
4

Eventually: We create a physical model in some (relational) database management system (DBMS) We translate the ER Model into a relational database Suppose we know of four student entities and two courses entities. For example, four students named John, Amelia, Lee, and April, and two courses Intro to Art and Intro to History. Information about these is listed below.

Students Name John Amelia Lee April Course Name

Id# 184 337 876 901

Phone 283-4984 838-3737 933-2211 644-3838

Course#

Dept Art History

Intro to Art 661 Intro to History 765

We can represent these two sets of entities using set diagrams. John Amelia Lee April set of students set of courses
7

Intro to Art Intro to History

Relationships describe how entities relate to one another

Suppose we have the two courses and four students listed previously. Suppose also that - John and Amelia are enrolled in Intro to Art - John and Lee are enrolled in Intro to History - April is not enrolled in any course. Below, we depict a relationship set and show the four instances of an enroll in relationship.

John Amelia Lee April Intro to Art Intro to History

Note there are four instances of enroll in. Each Instance involves exactly two entities: a student entity and a course entity. Because each instance of enroll in involves two entities, it is referred to as a binary relationship. Binary relationships will be the focus of most of our discussions.

10

An example of an Entity Relationship Model: Entities are indicated using rectangular shapes, and relationships between entities are shown with a diamond shape on a line connecting the entities. Students m Enroll-in n Course

Entity sets are shown with a rectangular shape. Relationship sets are shown with a diamond shape. The "m" indicates that one course may have many students enrolled in it. The "n" indicates that one student may have enrolled in many courses.
11

The ER model was introduced by Peter Chen in his paper The Entity-Relationship Model--Toward a Unified View of Data (ACM Transactions on Database Systems, Vol. 1, No. 1, 1976). This paper is one of the most cited papers in the computer field, and has been considered one of the most influential papers in computer science.

12

ERD symbols Entity Weak entity Relationship Identifying relationship name name Attribute Key attribute
13

ERD symbols name name name Composite attribute Derived attribute Mutlti-valued attribute Partial participation Total participation 1nN Cardinality
14

With attributes, etc:


fname name ssn bdate degree minit sex lname address salary

name number

location

works for
startdate

department
1
number of employees

employee
supervisor

N
supervisee

manages
hours

controls
N

supervision

works on

project
name number location

dependents of
N

dependent
name sex birthdate relationship
15

You might also like