EXERCISES

13.1 Draw the normal form hierarchy from memory. Include at least nine normal forms.

13.2 Define 6NF.

13.3 6NF relvars are sometimes said to be irreducible, and I noted in the body of the chapter that this was yet another of the many kinds of irreducibility that are relevant to design theory. How many different kinds can you identify?

13.4 Define (a) FD redundancy; (b) JD redundancy; (c) RFNF.

13.5 Take another look at the decomposition of relvar P in the body of the chapter into 6NF projections PN, PL, PW, and PC. Can you think of any improvements on that design?

13.6 You’re given a relvar R representing marriages, with attributes A, B, and C and predicate Person A married person B on date C. Assume no polygamy; assume also that no two persons marry each other more than once. What keys does R have? Does the JD {AB,BC,CA} hold? What’s the highest normal form R is in?

13.7 In the body of the chapter, I said a relvar could be in SKNF and not 5NF, and I proposed the following as an example of such a relvar:

  • Let relvar R have attributes A, B, and C (only); let AB, BC, and CA each be keys of R; and let the JD {AB,BC,CA}—call it J—hold in R.

But you might not unreasonably be a little suspicious of this example. To be more specific, you might be wondering whether a relvar could even exist that’s subject to exactly the specified key constraints and the specified JD (even though I did go on to give a slightly more concrete version of the example). Show the example is reasonable after all by demonstrating that in fact all possible sets of dependencies (FDs and JDs) are consistent, in the sense that at least one relation can always be found that satisfies all dependencies in the set.

13.8 Relvar SPJ′ from the section REDUNDANCY FREE NORMAL FORM was subject to what might be called a “symmetric” JD—viz., the JD {{SNO,PNO},{PNO,JNO},{JNO,SNO}}—and yet displayed some asymmetry also, in that just one of the three components of that JD corresponded to a key. Intuitively, you might expect the other two components to correspond to keys as well. Show this isn’t necessarily so.

13.9 Design a database for the following. The entities to be represented are soccer match fixtures for a certain team. For matches that have already been played, we wish to record “goals for” and “goals against”; however,

these two properties clearly make no sense for matches that have yet to be played. What normal forms are your relvars in?

13.10 Let relvar SCP have attributes SNO, PNO, and CITY and predicate Supplier SNO and part PNO are both located in city CITY. Can SCP be derived from our usual S, P, and SP relvars? What normal form is it in? Can you think of any conventional wisdom this example might fly in the face of?

13.11 Define DK/NF. Give an example of a relvar in 6NF that’s not in DK/NF.

13.12 What’s the difference between SKNF and overstrong PJ/NF? In fact, is there a difference?

13.13 Give definitions, as precise as you can make them, of the relational operators restriction and union.

13.14 In the body of the chapter, I showed informally how reducing a relvar to 6NF projections corresponded to reducing a conjunctive predicate to simple predicates. Could there be such a thing as a disjunctive predicate? How might a relvar correspond to such a predicate? What would be involved in reducing such a predicate to simple predicates?

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset