|
Denormalizing
Data
|
Denormalization
is a process for creating the optimal set of physical data structures,
such as tables, files, records, etc., to store 3rd normal
form data.
The
process starts by identifying real-life conditions and criteria
that influence data structures.
|
Example
Entities and Attributes
| Entity |
Attribute |
| A |
A1*,
A2, A3 |
| B |
B1*,
B2, B3 |
| C |
C1*,
C2, C3, C4 |
*key
of this entity
|
|
|
| Step
1: Group data components that share a common criteria
(e.g., updated in the same time interval, share response time
needs, under authority of single user-group, etc.). |
Attributes
with Common Criteria
| Attributes |
Criteria |
| A2,
C4, B3 |
are
always updated at the same time |
| A2,
C4 |
require
the same level of security |
| B3,
C2 |
are
under the same user group |
|
|
|
|
Step
2: Draw a line around the entities on the entity
relationship diagram that contain involved attributes.
If
you only need a subset of the attributes in an entity, identify
them.
|
Entity
Relationship Diagram Overlay

|
|
|
|
Step3:
- Compare
the drawings for each criteria in which an entity is
needed.
|
- Identify
common groupings and combine the attributes into specific
physical data structures.
|
- Add
the keys of all participating entities to the record.
|
- Create
a different record for each entity that contains attributes
that have not yet been assigned to a physical record.
The primary key of these records will be the primary key
of the
entity.
|
|
Potential
Physical Data Structures
| ID |
Record |
| R1 |
A1*, C1*, A2, C4 |
| R2 |
A1*, A3 |
| R3 |
B1*, B2, B3 |
| R4 |
C1*, C2, C3 |
*key
of this entity
|
|
|
Step
4: Evaluate the impact that your proposed
design will have on performance.
|
Potential
Impacts
|
ID
|
Impact
Statement |
| 1
|
Processing
an event that needs B3 and C2 will require 2 physical accesses
which doubles access time. |
| 2 |
Is
there an event that requires A2, A3, B3 and C2? That event
would require 4 physical accesses leading to unacceptable
response times. |
| 3 |
...... |
|
|