SlideShare a Scribd company logo
Database Concept
Part # 2
OUTLINE
 Database Concepts
 Database Management System
Architecture
 ERD model
 Entity Relationship Notation
 Understand concepts of cardinality ratio
 Understand concepts of Participation
Part # 2
Database Concepts
 Data:
 Known facts that can be recorded.
 Database:
 A collection of related data.
 For Example:
 Names, telephone numbers, and addresses of the people you
know.
 You may have recorded this data in an indexed address book
 or you may have stored it on a hard drive, using a personal
computer and software such as Microsoft Access.
 This collection of related data with an implicit meaning is a
database.
3
Part # 2
Database Concepts
 Data models:
 A group of concepts that describe the database structure that
contain different data types, relationships and constraints.
 Entity:
 Describing a real world object.
 Example: employee, student, and courses.
 It corresponds to a table that contains a collection of attributes.
 The entity can be a person, place, event or an object that help
the organization to maintain its data.
4
Part # 2
Database Concepts
 Attribute:
 It can be described as a property to the entity.
 For example, if we have an entity is called an employee, this
entity can have attributes such as name, age and salary.
 An attribute corresponds to a column or field in a table.
 The number of attributes is called the degree.
 Tuple:
 corresponds to a row in a table.
5
Part # 2
Database Concepts
 Relationship:
 It describes how entities related to each other.
 Primary key:
 An attribute which is a unique identifier in a table.
 The primary key can be consisting of one attribute or combination of
attributes which called a composite key.
 The value of the primary key cannot be repeated in the same column.
 Foreign Key:
 Is an attribute or set of attributes in a table that matches the primary key of
another table.
 Used to represent relationship between tuples of two relations.
 Composite Key:
 a primary key that consists of more than one attribute
6
Part # 2
Example
4170010
4182000
4182034
4188134
4189860
4192134
StudentNo
Al-Saleh
Al-Ghanem
Al-Fahad
Saod
Rashed
Al-Fahad
LName
Amal
Nora
Laila
Amal
Rana
Rania
FName Initial
M.
A.
A.
F.
I.
M.
DOB
04-06-78
02-12-79
01-11-74
22-04-73
30-01-78
19-03-79
GPA
3.91
4.20
4.01
3.01
2.31
3.50
STUDENT
Attributes
Tuples
Degree
Relation Name
Part # 2
Example
Relation Name ?……………………...........
Number of Tuples?…………………………
Example of Attribute: ………………………
Degree of relation?…………………………
Primary Key?.............................................
Part # 2
Data Types
Part # 2
Data Types
Part # 2
Properties of Entities
• The Entity has a name that is distinct from all other
Entity names in the relational database.
• Each attribute has a distinct name.
• The values of an attribute are all of the same
domain.
• Each tuple is distinct. There are no duplicate tuples.
• The order of attributes has no significance.
• The order of tuples has no significance.
Part # 2
Database Concepts
12
Database Management System (DBMS): software that is
used to create, maintain and update databases. It has an
interface which can be menu based or graphic based or form
based or can be a collection of all these forms.
Database administrators (DBA):
Responsible for the whole database including construction,
implementation, access privileges and authorization.
Part # 2
Database Management System
Architecture
The DBMS has three main
levels they are:
1- Internal level: that describes
the physical data model,
2- Conceptual level: Describes
structure of the whole database
for a community of users.
3- External level: Describes part
of the database that a particular
user group is interested in.
and hide other parts.
13
Figure 2.1 shows the three main levels
of the database Architecture
USER
VIEW
EXTENAL
LEVEL
CONCEPTUAL
LEVEL
INTERNA
LEVEL
Part # 2
Data Independence
 Capacity to change the schema at one level of a
database system Without having to change the
schema at the next higher level
 Types of data independence :
 Logical
 Physical
Part # 2
Types of data independence
 Logical
 is the capacity to change
the conceptual schema
without having to change
external schemas or
application programs.
 Physical
 is the capacity to change
the internal schema
without having to change
the conceptual schema.
Part # 2
What is ERD model?
 ERD stands for the Entity Relationship Diagram that describes
the representation of data including entities, attributes and
relationships within an organization. It is considered one of the
critical phases in the designing of databases.
Figure 2.2 shows a simple example for an ERD for a school
16
Part # 2
Entity Relationship Notation
 There are common notations used all over the world for
the database.
 There are many tools help designers to draw the ERD
with its different notations such as Microsoft Visio or
the Oracle Designers.
 Most of these tools eliminate the diamond relationship
and show the attributes inside the entity rectangle
related to these attributes.
17
Part # 2
18
 The major activity of this phase is identifying:
 Relationships
 Entities
 Attributes
Entity Relationship Notation
Part # 2
Notations for ER Diagram
Part # 2
Notations for ER Diagram
 In the ER Model, the notations 1-1, 1-M, M-M used to represent the
Cardinality ratio.
 the participation is representing as double line for the total
participation and one line for the partial participation as shown in
Figure 2.5.
20
Figure 2.5 shows database notation used in this course
Part # 2
 Strong entity: can be defined as the entity that can stand alone
without the needs for other entities such as the student entity, the
department entity and the Instructor entity and is represented by a
single rectangle.
21
Figure 2.6 shows an ERD with strong entities
Part # 2
 Weak entity: is the opposite of the strong entity which can be
defined as the entity that depends on another entity .it can be
represented in the ERD as a doubled line rectangle. The relation
between the weak entity and the owner entity is called the identifying
relationship and is represented in the ERD as doubled line diamond
22
Figure2.7 shows an ERD with a weak entity
Notations for ER Diagram
Part # 2
 Multi-valued attribute: This can be defined as the attribute that can
have more than one value such as spoken languages "Arabic and
English" can be represented in the ERD as an ellipse with double lines.
23
Figure 2.9 shows a multi-valued attribute
Notations for ER Diagram
Part # 2
 Derived attribute: an attribute that can be calculated from another
attribute, such as the age attribute which can be calculated from the
date of birth attribute
24
Figure 2.10 shows a derived attribute
Notations for ER Diagram
Part # 2
ERD Example
25
Part # 2
Activity 1
 Identify entities and attributes?
 Cars
 Phone Number
 Salary
 Products
 Date
 Height
 Employees
26
Part # 2
Activity 2
 Assume that you are designing a database
for school, what are the possible Entities,
Attributes and Keyes for the database?
27
Part # 2
What is the cardinality ratio
28
 It can be defined as the number of instances of an
entity that can be associated, participated or in a
relationship with another entity.
 It can be divided into Three main types :
o One to One (1:1)
o One to Many (1: M)
o Many to Many (M: M )
Part # 2
29
 A department must have only one employee, while the
employee must work in only one department .
Figure 2.14 shows I-I relationship
Example #1
Part # 2
 A department may have numbers of employee and each
employee must work only in one department
Figure 2.13 shows I-M relationship
30
Example #2
Part # 2
31
Example #3
 A department may have many employees, while the
employee may work in more than department.
Figure 2.15 shows M-M relationship with partial participation
Part # 2
32
What is the Participation
 Participation in database is used to describe how
the degree of participation that the entity will have
in the relationship.
 There are two main types of participation:
o Total participation : represented by two lines
o Partial participation : represented by only single
line.
Part # 2
 1- A department must employ an employee and the
employee must be employed by a department.
Figure 2.17 shows total participation from both sides
33
Participation Examples
Part # 2
 2- A department must employ an employee, while the
employee need not to be employed by a department
Figure 2.18 shows total participation from one side and partial participation from another side
34
Participation Examples
Part # 2
 3-A department may not need to employee any employee
and the employee needs not to be employed by a
department
Figure 2.19 shows partial participation from both sides
35
Participation Examples
Part # 2
Activity 3
36
What are the cardinality and participation types that are
suitable for this relation?
Part # 2
37

More Related Content

PPT
ERD_01B=DBMS DATA BASE MANAGEMENT SYSTEM.ppt
syedalishahid6
 
PPTX
Database part3-
Taymoor Nazmy
 
PPTX
IT6701 Information Management Unit-I
Mikel Raj
 
PPTX
Database management systems 3 - Data Modelling
Nickkisha Farrell
 
PPTX
Er model
Soumyajit Dutta
 
PPTX
er-models.pptx
UmmerFarooq24
 
PPTX
3 Entity Relationship (E-R) Modeling_chapter 3 (1).pptx
DanialKhawaja4
 
ERD_01B=DBMS DATA BASE MANAGEMENT SYSTEM.ppt
syedalishahid6
 
Database part3-
Taymoor Nazmy
 
IT6701 Information Management Unit-I
Mikel Raj
 
Database management systems 3 - Data Modelling
Nickkisha Farrell
 
Er model
Soumyajit Dutta
 
er-models.pptx
UmmerFarooq24
 
3 Entity Relationship (E-R) Modeling_chapter 3 (1).pptx
DanialKhawaja4
 

Similar to DB-Lec1.pptxUpdatedpython.pptxUpdatedpython.pptx (20)

PDF
Lecture 2 database management system.pdf
samerelking3
 
PPT
ERD(2).ppt
Vijaykumar311275
 
PPTX
database_design_presentation, data base design presenttion
ahtms257
 
PPTX
DBMS_Data Model,Keys,Attributes,Relationship.pptx
DrThenmozhiKarunanit
 
PDF
2_EntityRelationship-Model-241-trang-1.pdf
chang465730
 
PPT
Database Chapter 3
shahadat hossain
 
PPSX
Cn presentation on the topic called as re modelling
g30162363
 
PPT
Chapter3
Jafar Nesargi
 
PPT
Chapter3
Jafar Nesargi
 
PPTX
Database week 5 lecture includes spexiafix
tasleemasad33
 
PDF
Databases - Unit 2.pdf
CynthiaAdzornu
 
PPT
Lecture-13-ER Modeling using web architecture
NoorUlHaq47
 
PPT
Database Management System
FellowBuddy.com
 
PPT
ERD_01.ppt
sugandhi23
 
PPT
ERD_01.ppt
SayaliBelhe1
 
PPT
ERD merupakan suatu diagram yang berisi komponen- komponen himpunan entitas ...
huraitera
 
PPT
Data modeling using the entity relationship model
Jafar Nesargi
 
PPT
ER Diagram
Robby Firmansyah
 
PDF
ER diagram is created based on three principal components: entities, attribut...
athuathul507
 
Lecture 2 database management system.pdf
samerelking3
 
ERD(2).ppt
Vijaykumar311275
 
database_design_presentation, data base design presenttion
ahtms257
 
DBMS_Data Model,Keys,Attributes,Relationship.pptx
DrThenmozhiKarunanit
 
2_EntityRelationship-Model-241-trang-1.pdf
chang465730
 
Database Chapter 3
shahadat hossain
 
Cn presentation on the topic called as re modelling
g30162363
 
Chapter3
Jafar Nesargi
 
Chapter3
Jafar Nesargi
 
Database week 5 lecture includes spexiafix
tasleemasad33
 
Databases - Unit 2.pdf
CynthiaAdzornu
 
Lecture-13-ER Modeling using web architecture
NoorUlHaq47
 
Database Management System
FellowBuddy.com
 
ERD_01.ppt
sugandhi23
 
ERD_01.ppt
SayaliBelhe1
 
ERD merupakan suatu diagram yang berisi komponen- komponen himpunan entitas ...
huraitera
 
Data modeling using the entity relationship model
Jafar Nesargi
 
ER Diagram
Robby Firmansyah
 
ER diagram is created based on three principal components: entities, attribut...
athuathul507
 

More from ZahouAmel1 (18)

PPTX
2- lec_2.pptxDesigning with Type, SpacingDesigning with Type, SpacingDesignin...
ZahouAmel1
 
PPTX
1-Lect_1.pptxLecture 5 array in PHP.pptx
ZahouAmel1
 
PPTX
Lecture 8 PHP and MYSQL part 2.ppType Classificationtx
ZahouAmel1
 
PPTX
Lecture 9 CSS part 1.pptxType Classification
ZahouAmel1
 
PPTX
Lecture 5 array in PHP.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
PPTX
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
PPTX
Lecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
PPTX
Lec 1 Introduction to Computer and Information Technology #1.pptx
ZahouAmel1
 
PPTX
DB- lec2.pptxUpdatedpython.pptxUpdatedpy
ZahouAmel1
 
PPTX
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
ZahouAmel1
 
PPTX
4-Lect_4-2.pptx4-Lect_4-2.pptx4-Lect_4-2.pptx
ZahouAmel1
 
PPTX
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
ZahouAmel1
 
PPTX
6-LEC- 6.pptx Network Layer. Addressing Subnetting Mask (default and subnet) ...
ZahouAmel1
 
PPTX
7-Lect_7 .pptxNetwork Layer. Addressing Subnetting Mask (default and subnet) ...
ZahouAmel1
 
PPTX
7-Lect_7 .pptxNetwork LayerNetwork Layer
ZahouAmel1
 
PPTX
8-Lect_8 Addressing the Network.tcp.pptx
ZahouAmel1
 
PPTX
9-Lect_9-1.pptx9-Lect_9-1.pptx9-Lect_9-1.pptx
ZahouAmel1
 
PPTX
9-Lect_9-2.pptx DataLink Layer DataLink Layer
ZahouAmel1
 
2- lec_2.pptxDesigning with Type, SpacingDesigning with Type, SpacingDesignin...
ZahouAmel1
 
1-Lect_1.pptxLecture 5 array in PHP.pptx
ZahouAmel1
 
Lecture 8 PHP and MYSQL part 2.ppType Classificationtx
ZahouAmel1
 
Lecture 9 CSS part 1.pptxType Classification
ZahouAmel1
 
Lecture 5 array in PHP.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
Lecture 2 HTML part 1.pptxLecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
Lecture 10 CSS part 2.pptxvvvvvvvvvvvvvv
ZahouAmel1
 
Lec 1 Introduction to Computer and Information Technology #1.pptx
ZahouAmel1
 
DB- lec2.pptxUpdatedpython.pptxUpdatedpy
ZahouAmel1
 
Updatedpython.pptxUpdatedpython.pptxUpdatedpython.pptx
ZahouAmel1
 
4-Lect_4-2.pptx4-Lect_4-2.pptx4-Lect_4-2.pptx
ZahouAmel1
 
5-LEC- 5.pptxTransport Layer. Transport Layer Protocols
ZahouAmel1
 
6-LEC- 6.pptx Network Layer. Addressing Subnetting Mask (default and subnet) ...
ZahouAmel1
 
7-Lect_7 .pptxNetwork Layer. Addressing Subnetting Mask (default and subnet) ...
ZahouAmel1
 
7-Lect_7 .pptxNetwork LayerNetwork Layer
ZahouAmel1
 
8-Lect_8 Addressing the Network.tcp.pptx
ZahouAmel1
 
9-Lect_9-1.pptx9-Lect_9-1.pptx9-Lect_9-1.pptx
ZahouAmel1
 
9-Lect_9-2.pptx DataLink Layer DataLink Layer
ZahouAmel1
 

Recently uploaded (20)

PPTX
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
PDF
Research-Fundamentals-and-Topic-Development.pdf
ayesha butalia
 
PDF
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
PDF
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
PDF
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
PPTX
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
PDF
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
PDF
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
PDF
Using Anchore and DefectDojo to Stand Up Your DevSecOps Function
Anchore
 
PDF
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
PDF
Advances in Ultra High Voltage (UHV) Transmission and Distribution Systems.pdf
Nabajyoti Banik
 
PPTX
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
PDF
How-Cloud-Computing-Impacts-Businesses-in-2025-and-Beyond.pdf
Artjoker Software Development Company
 
PDF
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
PDF
BLW VOCATIONAL TRAINING SUMMER INTERNSHIP REPORT
codernjn73
 
PDF
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
PDF
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
PDF
Trying to figure out MCP by actually building an app from scratch with open s...
Julien SIMON
 
PDF
Doc9.....................................
SofiaCollazos
 
PDF
Event Presentation Google Cloud Next Extended 2025
minhtrietgect
 
What-is-the-World-Wide-Web -- Introduction
tonifi9488
 
Research-Fundamentals-and-Topic-Development.pdf
ayesha butalia
 
MASTERDECK GRAPHSUMMIT SYDNEY (Public).pdf
Neo4j
 
Get More from Fiori Automation - What’s New, What Works, and What’s Next.pdf
Precisely
 
Economic Impact of Data Centres to the Malaysian Economy
flintglobalapac
 
AI and Robotics for Human Well-being.pptx
JAYMIN SUTHAR
 
Unlocking the Future- AI Agents Meet Oracle Database 23ai - AIOUG Yatra 2025.pdf
Sandesh Rao
 
AI Unleashed - Shaping the Future -Starting Today - AIOUG Yatra 2025 - For Co...
Sandesh Rao
 
Using Anchore and DefectDojo to Stand Up Your DevSecOps Function
Anchore
 
CIFDAQ's Market Wrap : Bears Back in Control?
CIFDAQ
 
Advances in Ultra High Voltage (UHV) Transmission and Distribution Systems.pdf
Nabajyoti Banik
 
AI in Daily Life: How Artificial Intelligence Helps Us Every Day
vanshrpatil7
 
How-Cloud-Computing-Impacts-Businesses-in-2025-and-Beyond.pdf
Artjoker Software Development Company
 
NewMind AI Weekly Chronicles - July'25 - Week IV
NewMind AI
 
BLW VOCATIONAL TRAINING SUMMER INTERNSHIP REPORT
codernjn73
 
How Open Source Changed My Career by abdelrahman ismail
a0m0rajab1
 
OFFOFFBOX™ – A New Era for African Film | Startup Presentation
ambaicciwalkerbrian
 
Trying to figure out MCP by actually building an app from scratch with open s...
Julien SIMON
 
Doc9.....................................
SofiaCollazos
 
Event Presentation Google Cloud Next Extended 2025
minhtrietgect
 

DB-Lec1.pptxUpdatedpython.pptxUpdatedpython.pptx

  • 2. Part # 2 OUTLINE  Database Concepts  Database Management System Architecture  ERD model  Entity Relationship Notation  Understand concepts of cardinality ratio  Understand concepts of Participation
  • 3. Part # 2 Database Concepts  Data:  Known facts that can be recorded.  Database:  A collection of related data.  For Example:  Names, telephone numbers, and addresses of the people you know.  You may have recorded this data in an indexed address book  or you may have stored it on a hard drive, using a personal computer and software such as Microsoft Access.  This collection of related data with an implicit meaning is a database. 3
  • 4. Part # 2 Database Concepts  Data models:  A group of concepts that describe the database structure that contain different data types, relationships and constraints.  Entity:  Describing a real world object.  Example: employee, student, and courses.  It corresponds to a table that contains a collection of attributes.  The entity can be a person, place, event or an object that help the organization to maintain its data. 4
  • 5. Part # 2 Database Concepts  Attribute:  It can be described as a property to the entity.  For example, if we have an entity is called an employee, this entity can have attributes such as name, age and salary.  An attribute corresponds to a column or field in a table.  The number of attributes is called the degree.  Tuple:  corresponds to a row in a table. 5
  • 6. Part # 2 Database Concepts  Relationship:  It describes how entities related to each other.  Primary key:  An attribute which is a unique identifier in a table.  The primary key can be consisting of one attribute or combination of attributes which called a composite key.  The value of the primary key cannot be repeated in the same column.  Foreign Key:  Is an attribute or set of attributes in a table that matches the primary key of another table.  Used to represent relationship between tuples of two relations.  Composite Key:  a primary key that consists of more than one attribute 6
  • 7. Part # 2 Example 4170010 4182000 4182034 4188134 4189860 4192134 StudentNo Al-Saleh Al-Ghanem Al-Fahad Saod Rashed Al-Fahad LName Amal Nora Laila Amal Rana Rania FName Initial M. A. A. F. I. M. DOB 04-06-78 02-12-79 01-11-74 22-04-73 30-01-78 19-03-79 GPA 3.91 4.20 4.01 3.01 2.31 3.50 STUDENT Attributes Tuples Degree Relation Name
  • 8. Part # 2 Example Relation Name ?……………………........... Number of Tuples?………………………… Example of Attribute: ……………………… Degree of relation?………………………… Primary Key?.............................................
  • 10. Part # 2 Data Types
  • 11. Part # 2 Properties of Entities • The Entity has a name that is distinct from all other Entity names in the relational database. • Each attribute has a distinct name. • The values of an attribute are all of the same domain. • Each tuple is distinct. There are no duplicate tuples. • The order of attributes has no significance. • The order of tuples has no significance.
  • 12. Part # 2 Database Concepts 12 Database Management System (DBMS): software that is used to create, maintain and update databases. It has an interface which can be menu based or graphic based or form based or can be a collection of all these forms. Database administrators (DBA): Responsible for the whole database including construction, implementation, access privileges and authorization.
  • 13. Part # 2 Database Management System Architecture The DBMS has three main levels they are: 1- Internal level: that describes the physical data model, 2- Conceptual level: Describes structure of the whole database for a community of users. 3- External level: Describes part of the database that a particular user group is interested in. and hide other parts. 13 Figure 2.1 shows the three main levels of the database Architecture USER VIEW EXTENAL LEVEL CONCEPTUAL LEVEL INTERNA LEVEL
  • 14. Part # 2 Data Independence  Capacity to change the schema at one level of a database system Without having to change the schema at the next higher level  Types of data independence :  Logical  Physical
  • 15. Part # 2 Types of data independence  Logical  is the capacity to change the conceptual schema without having to change external schemas or application programs.  Physical  is the capacity to change the internal schema without having to change the conceptual schema.
  • 16. Part # 2 What is ERD model?  ERD stands for the Entity Relationship Diagram that describes the representation of data including entities, attributes and relationships within an organization. It is considered one of the critical phases in the designing of databases. Figure 2.2 shows a simple example for an ERD for a school 16
  • 17. Part # 2 Entity Relationship Notation  There are common notations used all over the world for the database.  There are many tools help designers to draw the ERD with its different notations such as Microsoft Visio or the Oracle Designers.  Most of these tools eliminate the diamond relationship and show the attributes inside the entity rectangle related to these attributes. 17
  • 18. Part # 2 18  The major activity of this phase is identifying:  Relationships  Entities  Attributes Entity Relationship Notation
  • 19. Part # 2 Notations for ER Diagram
  • 20. Part # 2 Notations for ER Diagram  In the ER Model, the notations 1-1, 1-M, M-M used to represent the Cardinality ratio.  the participation is representing as double line for the total participation and one line for the partial participation as shown in Figure 2.5. 20 Figure 2.5 shows database notation used in this course
  • 21. Part # 2  Strong entity: can be defined as the entity that can stand alone without the needs for other entities such as the student entity, the department entity and the Instructor entity and is represented by a single rectangle. 21 Figure 2.6 shows an ERD with strong entities
  • 22. Part # 2  Weak entity: is the opposite of the strong entity which can be defined as the entity that depends on another entity .it can be represented in the ERD as a doubled line rectangle. The relation between the weak entity and the owner entity is called the identifying relationship and is represented in the ERD as doubled line diamond 22 Figure2.7 shows an ERD with a weak entity Notations for ER Diagram
  • 23. Part # 2  Multi-valued attribute: This can be defined as the attribute that can have more than one value such as spoken languages "Arabic and English" can be represented in the ERD as an ellipse with double lines. 23 Figure 2.9 shows a multi-valued attribute Notations for ER Diagram
  • 24. Part # 2  Derived attribute: an attribute that can be calculated from another attribute, such as the age attribute which can be calculated from the date of birth attribute 24 Figure 2.10 shows a derived attribute Notations for ER Diagram
  • 25. Part # 2 ERD Example 25
  • 26. Part # 2 Activity 1  Identify entities and attributes?  Cars  Phone Number  Salary  Products  Date  Height  Employees 26
  • 27. Part # 2 Activity 2  Assume that you are designing a database for school, what are the possible Entities, Attributes and Keyes for the database? 27
  • 28. Part # 2 What is the cardinality ratio 28  It can be defined as the number of instances of an entity that can be associated, participated or in a relationship with another entity.  It can be divided into Three main types : o One to One (1:1) o One to Many (1: M) o Many to Many (M: M )
  • 29. Part # 2 29  A department must have only one employee, while the employee must work in only one department . Figure 2.14 shows I-I relationship Example #1
  • 30. Part # 2  A department may have numbers of employee and each employee must work only in one department Figure 2.13 shows I-M relationship 30 Example #2
  • 31. Part # 2 31 Example #3  A department may have many employees, while the employee may work in more than department. Figure 2.15 shows M-M relationship with partial participation
  • 32. Part # 2 32 What is the Participation  Participation in database is used to describe how the degree of participation that the entity will have in the relationship.  There are two main types of participation: o Total participation : represented by two lines o Partial participation : represented by only single line.
  • 33. Part # 2  1- A department must employ an employee and the employee must be employed by a department. Figure 2.17 shows total participation from both sides 33 Participation Examples
  • 34. Part # 2  2- A department must employ an employee, while the employee need not to be employed by a department Figure 2.18 shows total participation from one side and partial participation from another side 34 Participation Examples
  • 35. Part # 2  3-A department may not need to employee any employee and the employee needs not to be employed by a department Figure 2.19 shows partial participation from both sides 35 Participation Examples
  • 36. Part # 2 Activity 3 36 What are the cardinality and participation types that are suitable for this relation?