Professional Documents
Culture Documents
Databases Course 3: Data Models
Databases Course 3: Data Models
Databases Course 3: Data Models
Course 3
Data Models
Delia-Alexandrina Mitrea, S.L. Eng.,PhD
E-mail: Delia.Mitrea@cs.utcluj.ro
modeling.
Definition of a data model
Data models classification
Abstractization, generalization, aggregation
Entities, connections between the entities
Most significant data models
The hierarchical data model
The network data model
The relational data model. The EntityRelationship (ER) model
The Entity-Relationship (ER) model detailed
Topics to review
Technically speaking:
A data model is a formalism having two components:
A set of rules for data structuring and organization
A set of rules for data manipulation
A data model
The database
The rules for data structuring and the operations allowed on the data are defined
within the data model
called Gs
the part responsible for the specification of the constraints, called
Gc
Abstractization,
generalization,
aggregation
Abstractization, generalization,
aggregation
The abstractization
neglecting the non-relevant aspects and concentrating on the
properties of interest
The generalization
The aggregation
Generalization
Generalization hierarchy
Example: the university domain
Person
Student
Employee
Administrative Person
Technician
Secretary
Teacher
As.
Lect.
Conf.
Prof.
Aggregation
Aggregation hierarchy
Person
Name
Address
Age
Town
Street
Number
Employee
Function
Salary
Address
Age
Student
Specialization
Year
What is an entity?
(1)
(2)
Usual employees
Teacher
Student
Room
be easily understood
tables
OBS.2:
Employees
USUAL
EMPLOYEES
Teachers
TEACHER
Given Marks
Marks
Received Marks
STUDENT
Rooms
ROOM
M1
M2
Mn
M1
M2
Mn
M1
M2
P
Mn
M1
M2
Mn
trivial operation
when a new student is added, the chain of the connection
elements will be empty, and will consist from a single
pointer representing a connection from the new record to
itself
one can delete a teacher without affecting the
corresponding students that exist through themselves
the student appears within a single database record => there isnt
any risk of inconsistence resulted from the update operation
OBS: The relational data model stands at the basics of the majority
of commercial DBMS, that exist and appear nowadays.
RL features:
Ability to allow the definition of new relations based on the existing
ones
Allow the development, with relational DBMS, of some flexible and
friendly interfaces, having the possibility to be directly explored by
much larger user categories, compared with the case of the network
and relational databases
Codd's Rules
A relational database management system (R DBMS) must manage its
stored data using only its relational capabilities
Rules primarily address implementation requirements for RDBMS
vendors
Some of them also have an impact on application design
1. Information rule
All information in the database should be represented in one and only one
way : as values in a table
as ordinary data