Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
0% found this document useful (0 votes)
15 views

Lecture 8 ER Model

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
15 views

Lecture 8 ER Model

Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

8/27/2022

DBMS: Course Objectives


COURSE OBJECTIVES

APEX INSTITUTE OF TECHNOLOGY The Course aims to:


• Understand database system concepts and design databases for different applications
DEPARTMENT OF COMPUTER SCIENCE & ENGINEERING
and to acquire the knowledge on DBMS and RDBMS.
• Implement and understand different types of DDL, DML and DCL statements.
Database Management System (21CSH-243)
• Understand transaction concepts related to databases and recovery/backup techniques
Faculty: Prof. (Dr.) Vineet Mehan (E13038)
required for the proper storage of data.

Lecture - 8 DISCOVER . LEARN . EMPOWER


1 2
ER Model

COURSE OUTCOMES Unit-1 Syllabus


Unit-1 Introduction to Databases and Relational Algebra
On completion of this course, the students shall be able to:-
Overview of Database concepts, DBMS, Data Base System Architecture (Three
Understand the database concept, system architecture and role of database Databases: Level ANSI-SPARC Architecture), Advantages and Disadvantages of
CO1
administrator DBMS, Data Independence, DBA and Responsibilities of DBA,
Relational Data Structure, Keys, Relations, Attributes, Schema and
Instances, Referential integrity, Entity integrity.

Data Models: Relational Model, Network Model, Hierarchical Model, ER Model:


Design, issues, Mapping constraints, ER diagram, Comparison of
Models
Relational Introduction, Syntax, Semantics, Additional operators, Grouping and
Algebra & Ungrouping, Relational comparisons, Tuple Calculus, Domain
Relational Calculus, Calculus Vs Algebra, Computational capabilities
Calculus:
3 4

SUGGESTIVE READINGS The E-R Model


• TEXT BOOKS • E stands for Entity.
• Ramez Elmasri and Shamkant B. Navathe, “Fundamentals of Database
System”, The Benjamin / Cummings Publishing Co
• Korth and Silberschatz Abraham, “Database System Concepts”, McGraw Hall • R stands for Relationship.
• Pratt, “ DBMS”, Cengage Learning
• E-R combination makes Entity Relationship Model.
• REFERENCE BOOKS
• C.J.Date, “An Introduction to Database Systems”, Addison Wesley
• Rob,” Database Principal Fundamental Design, Cengage Learning • An ER model is an abstract way of describing a database.

By: Pramod Vishwakarma (E9758) 5 6

1
8/27/2022

E-R Diagram COMPONENTS OF AN E-R DIAGRAM


1. ENTITY
• ER-Diagram is a visual representation of data that describes
how data is related to each other. WEAK ENTITY

2. ATTRIBUTE
KEY ATTRIBUTE
COMPOSITE ATTRIBUTE

3. RELATIONSHIP

7 8

1. ENTITY ENTITY
• An Entity can be any object, place, person or class.
• Consider an example of an Organisation.

• In E-R Diagram, an entity is represented using rectangles.


• Employee, Manager, Department, Product and many more
can be taken as entities from an Organisation.

Entity

9 10

WEAK ENTITY 2. ATTRIBUTE


• An Attribute describes a property or characteristic of an entity.
• Weak entity is an entity that depends on another entity.

• For example, Name, Age, Address, ID etc. can be attributes of a


• Weak entity does not have key attribute of their own. Student.

• Double rectangle represents weak entity. • An attribute is represented using eclipse.

ATTRIBUTE

11 12

2
8/27/2022

ATTRIBUTE KEY ATTRIBUTE


• Key attribute represents the main characteristic of an Entity.

• It is used to represent Primary key.

• Ellipse with underlying lines represent Key Attribute.

13 14

COMPOSITE ATTRIBUTE
KEY ATTRIBUTE
• An attribute can also have their own attributes.

• These attributes are known as Composite attribute.

15 16

3. RELATIONSHIPS RELATIONSHIPS
• There are three types of relationship that exist between Entities.
• A Relationship describes relations between entities.

3.1 Binary Relationship


• Relationship is represented using diamonds.

3.2 Recursive Relationship

3.3 Ternary Relationship

17 18

3
8/27/2022

3.1 BINARY RELATIONSHIP 3.1.1 One to One


• Binary Relationship means relation between two Entities.
• This type of relationship is rarely seen in real world.

• This is further divided into three types.


• One student can enroll only for one course and a course will
also have only one Student.
3.1.1 One to One
3.1.2 One to Many
3.1.3 Many to Many

19 20

3.1.2 One to Many 3.1.3 Many to Many

• It reflects business rule that one entity is associated with


many number of same entity.

• For example, Student enrolls for only one Course but a


Course can have many Students.

21 22

3.2 Recursive Relationship Recursive Relationship


• A recursive relationship is a relationship between an entity and itself.
• 1:1 unary relationship

• Also called as Unary Relationship • A Person may be married to only one Person.

• A unary relationship is when both participants in the relationship are


the same entity.

23 24

4
8/27/2022

Recursive Relationship Recursive Relationship

• 1:M unary relationship • M:N unary relationship

• An Employee may manage many Employees, but an • A Subject may have many other Subjects as prerequisites
Employee is managed by only one Employee. and each Subject may be a prerequisite to many other
Subjects

25 26

3.3 Ternary Relationship Summary


• ER Model
• A ternary relationship is when three entities participate in
the relationship.
• Component of ER Model
• For Example: The University might need to record which
teachers taught which subjects in which courses

27 28

Assessment Questions REFERENCES


• Construct an ER diagram for Car Insurance Company whose • http://www.cs.sfu.ca/CourseCentral/354/zaiane/material/notes/Chap
customers owns more than one cars. Each car is associated with zero ter1/node4.html
to any number of recorded accidents. • www.studytonight.com/dbms/er-diagram.php

29 30

5
8/27/2022

THANK YOU

For queries
Email: vineet.e13038@cumail.in
31

You might also like