Conceptual Data Models 2020
Conceptual Data Models 2020
Conceptual Data Models 2020
1
Types Of Data Models
1. Object Based Logical Models
- They are used in describing data at the
conceptual and view levels.
- They provide fairly flexible structuring
capabilities and allow data constraints to
be specified explicitly.
Types Of Data Models cont’d
They include:
E - R Model
Binary Model
Function
Types Of Data Models cont’d
2. Record Based Logical Models
These are models used in describing data at the conceptual
and view levels.
They are used to specify the overall logical structure of the
database and to provide a higher-level description
implementation.
It is hard to understand.
level.
They are very few in number and the two widely known ones
Entity sets
Attributes
Relationship sets
Student_First_Name
Student_MI
Student_Last_Name
Student
Student_ID Student_Address_Line_1
Student_Name Student_Address_Line_2
Student_Address Student_City
Student_DOB Student_State
Student_Class Student_Country
Student_Postal_Code
Single valued and Multi valued Attribute -
The social security number or ID number can
only have a single value at any instance and
therefore its said to be single valued.
An attribute like dependant name can take
several values ranging from o-n thus it is said to
be multi valued.
Multi-Valued Attributes
Student Employee
Student_ID (PK) Employee_ID (PK)
Student_First_Name Employee_First_Name
Student_Last_Name Employee_Last_Name
Student_Address Employee_Address
Student_DOB Employee_DOB
Student_Class Employee_Dependent1
Student_Phone1 Employee_Dependent2
Student_Phone2
Calculated/derived attribute
STUDENT
3. Relationship sets
An association between two or more entities is called a
relationship. Ie connects 2 entities
Relationship set: Collection of similar relationships
among two or more entity sets.
It indicates that there is a business relationship between
these Entity Types.
They represent logical links between two or
more entities.
Represented by
(1,1) enr (1,M)
STUDENT ollm UNIVERSITY
ent
Instances of an ER Diagram
Employee
Structured constrains
(Cardinalities)
These are specified for each entity participating in a
relationship and describe the maximum and
minimum number of relationship occurrences in
which an entity occurrence can participate.
Cardinalities state how many times can an entity
instance participate in instances of a given
relationship.
Structured constrains
(Cardinalities)
• Optional relationships are shown by either, use of
a small circle drawn along the line or a dotted line
• Mandatory relationships are shown by use of
either a bar drawn across the line or a continuous
line
ER Model Notation
Represent entities as rectangles
List attributes within the rectangle
Entity UniversityStudent
StudentName
Attributes StudentDOB
StudentAge
Weak Entity Set -This is an entity set that does not
have sufficient attributes to form a primary
Strong Entity Set -This is an entity set that has a
primary key..
Specialisation -An entity set may include sub-groupings of
entities that are distinct in some way from other entities in
the set. This is called specialization of the entity set
Aggregation- This is abstraction through which relationship
are treated as higher-level entities e.g. the relationship set
borrower and the entity sets customer and loan can be
treated as a higher set called borrower as a whole.
Primary and Foreign Keys
Primary keys enforce entity integrity by uniquely identifying
entity instances.
The primary key is an attribute or a set of attributes that uniquely
identify a specific instance of an entity.
Foreign keys enforce referential integrity by completing an
association between two entities.