Database Reference
In-Depth Information
Modeling Theory
Everything begins with a theory, and in IT, the theory is the way things
would be done in a perfect world. Unfortunately, we do not live in a per-
fect world, and things must be adapted for them to be successful. That
said, you still have to understand the theory so that you can come as close
as possible. There is always a reason behind a theory, and understanding
these underlying reasons will make you a better data modeler.
Data modeling is not a new idea, and there are many resources on
database design theory and methodology; a few titles focus on nothing
more than the symbols you can use to draw diagrams. That being the case,
we do not focus on the methodology and theory; instead we discuss the
most important components of the theory and focus on putting these the-
ories into practice.
Logical Elements
When you start modeling, you begin with the logical modeling. The logi-
cal model is a representation of the data in a way that can be presented to
the business as well as serve as a road map for the physical implantation.
The main elements of a logical model are entities, attributes, and relation-
ships. Entities are logical groupings of data, such as all the information
that describes a customer. Attributes are the pieces of information that
make up entities. For a customer, the attributes might be things like name,
address, or phone number. Relationships describe how one entity is re-
lated to another. For example, the relationship “customers place orders”
describes the fact that customers “own” the orders they place. We dive
deeper into logical elements and explain how they are used in Chapter 2,
Elements Used in Logical Data Models.
Physical Elements
Once the logical model is constructed you create the physical model. Like
the logical model, the physical model is made up of various elements.
Tables are where everything is stored. Tables have columns, which contain
the information about the data in the table rows. SQL Server also provides
primary and foreign keys (defined in Chapter 2), which allow you to define
the relationship between two tables.
At first glance, tables, columns, and keys might seem to be the same
as the logical elements, but there are important differences. Logical
Search WWH ::




Custom Search