Databases Reference
In-Depth Information
Exhibit 20-5. Employee entity constraint matrix.
number of additional entities and relationships that are required in typical
entity-relationship diagrams. An alternative is to diagram only the super-
type entity as part of the entity-relationship model and to include an entity
constraint matrix as part of the model's documentation. An entity con-
straint matrix can be created for any entity in the entity-relationship dia-
gram. The columns in the matrix are the outbound properties associated
with the supertype entity and the rows are the various subtypes that are
analyzed. By drawing the entity constraint matrix the modeler asserts that
the entity is a supertype without the need to clutter the entity-relationship
diagram with all the subtyping details.
Exhibit 5 illustrates an entity constraint matrix for EMPLOYEE. The six
columns correspond to the six properties of the EMPLOYEE entity that can
be constrained. Properties that are required singly (e.g., [1:1] NAME) can-
not be constrained and do not appear in the matrix. The matrix rows are
the seven subtypes that are defined for EMPLOYEE. The matrix cells repre-
sent additional constraints placed on the model whenever the subtypes
are referenced. The data modeler can describe all of the matrix's informa-
tion by using traditional entity-relationship diagramming techniques. The
entity constraint matrix can capture these facts in a less cumbersome way
and can avoid the pitfalls associated with traditional subtype modeling by
using entity-relationship diagramming. The object proliferation problem
still exists, but the diagrammatic complexity associated with that prolifer-
ation is eliminated.
The entity constraint matrix also avoids the arbitrary nature of decom-
position. Each row specifies the rule necessary to create a subset. These
Search WWH ::




Custom Search