Download free books at BookBooN.com
An Introduction to Relational Database Theory
177
Database Design I: Projection-Join Normalization
For convenience, I shall refer to the components of a JD{ Wife#, FirstName } and { Wife#,
LastName, Fate } in this exampleas projections, and the number of projections as the degree of the
JD. This one is of degree 2 and is therefore called a binary JD. The symbol * is often used in textbooks for
the join operator. Because the operands of a JD are projections they are indicated by lists of attribute
names enclosed in braces; those operands are in turn enclosed in braces because in general a join
dependency can involve any number of projections and, thanks to the commutativity and associativity of
the join operator, the order in which those projections are written is insignificant.
Note that the formulation shown for one of the JDs to which WIFE_OF_HENRY_VIII is subject makes
no mention of that relvar. Whenever we mention a JD it must be clear from the context to which relvar it
applies. We normally do that by stating whether the given JD holds in that relvar. The JD in our example
does indeed hold in WIFE_OF_HENRY_VIII. By contrast, the JD
* { { Wife#, FirstName }, { LastName, Fate } }
for example, does not hold in that relvar, because the following tuple, among several others, appears in the
join of those two projections but does not appear in the current value of WIFE_OF_HENRY_VIII:
TUPLE { Wife# 1, FirstName 'Anne',
LastName 'Parr', Fate 'survived' }
Note that in the projection over { LastName, Fate } we lose the information that Seymour is the last
name of wife number 3, for example. Conversely, in the join we “gain” the misinformation represented by
those tuples that do not appear in WIFE_OF_HENRY_VIII. To put it more accurately, the predicate for
WIFE_OF_HENRY_VIII does not apply to the result of this join, so the information represented is
different too. (Exercise for the reader: what predicate does apply to it?)
Note that a JD cannot possibly hold in its applicable relvar, r, unless each attribute of r appears in at least
one of the projections. If that is not the case, then the join of those projections does not have the same
heading as r and therefore cannot be equal to r.
You have probably noticed that W_LN_F, in whose predicate the word Āandā still appears, can be
further decomposed. I’ll come back to this point in a moment. W_FN, however, cannot be further
decomposed. We say that relvar W_FN is an irreducible relvar. We also say that relvar W_FN is in sixth
normal form (6NF), whereas
W_LN_F
is not in 6NF and nor is WIFE_OF_HENRY_VIII. You are right
in guessing from the name, sixth normal form, that other normal forms have been identified, at least five
of which are identified by numbers. In fact several others have been defined around the idea of eliminating
certain JDs, varying according to exactly which particular kinds of JD they eliminate. Fortunately, some
of them can now safely be regarded as preliminary ideas by researchers, later subsumed by more general
and more useful definitions. Nowadays it is sufficient to study just three ĀJD-eliminatingā normal forms.
In this book I refer to them as projection-join normal forms, but please note that the term projection-join
normal form (PJ/NF) is used by some writersincluding its originator, Fagin [12]to refer specifically to
just one of these three (namely, 5NF).