| A data model is a
conceptual representation of the data structures that
are required by a database. The data structures include
the data objects, the associations between data objects,
and the rules which govern operations on the objects. As
the name implies, the data model focuses on what data is
required and how it should be organized rather than what
operations will be performed on the data. To use a
common analogy, the data model is equivalent to an
architect's building plans.
A data model is independent of hardware or software
constraints. Rather than try to represent the data as a
database would see it, the data model focuses on
representing the data as the user sees it in the "real
world". It serves as a bridge between the concepts that
make up real-world events and processes and the physical
representation of those concepts in a database.
Methodology
There are two major methodologies used to create a
data model: the Entity-Relationship (ER) approach and
the Object Model. This document uses the
Entity-Relationship approach.
Data Modeling In the Context of Database Design
Database design is defined as: "design the logical
and physical structure of one or more databases to
accommodate the information needs of the users in an
organization for a defined set of applications". The
design process roughly follows five steps:
- planning and analysi
- conceptual design
- logical design
- physical design
- implementation
The data model is one part of the conceptual design
process. The other, typically is the functional model.
The data model focuses on what data should be stored in
the database while the functional model deals with how
the data is processed. To put this in the context of the
relational database, the data model is used to design
the relational tables. The functional model is used to
design the queries which will access and perform
operations on those tables.
Components of A Data Model
The data model gets its inputs from the planning and
analysis stage. Here the modeler, along with analysts,
collects information about the requirements of the
database by reviewing existing documentation and
interviewing end-users.
The data model has two outputs. The first is an
entity-relationship diagram which represents the data
structures in a pictorial form. Because the diagram is
easily learned, it is valuable tool to communicate the
model to the end-user. The second component is a data
document. This a document that describes in detail the
data objects, relationships, and rules required by the
database. The dictionary provides the detail required by
the database developer to construct the physical
database.
Why is Data Modeling Important?
Data modeling is probably the most labor intensive
and time consuming part of the development process. Why
bother especially if you are pressed for time? A common
response by practitioners who write on the subject is
that you should no more build a database without a model
than you should build a house without blueprints.
The goal of the data model is to make sure that the
all data objects required by the database are completely
and accurately represented. Because the data model uses
easily understood notations and natural language , it
can be reviewed and verified as correct by the
end-users.
The data model is also detailed enough to be used by
the database developers to use as a "blueprint" for
building the physical database. The information
contained in the data model will be used to define the
relational tables, primary and foreign keys, stored
procedures, and triggers. A poorly designed database
will require more time in the long-term. Without careful
planning you may create a database that omits data
required to create critical reports, produces results
that are incorrect or inconsistent, and is unable to
accommodate changes in the user's requirements.
Summary
A data model is a plan for building a database. To be
effective, it must be simple enough to communicate to
the end user the data structure required by the database
yet detailed enough for the database design to use to
create the physical structure.
The Entity-Relation
Model (ER) is the most common method used to
build data models for relational databases. |