CHAPTER 3

3.1 With reference to the sample value shown for relvar STP in Chapter 1 (Figure 1-2), we can’t insert the fact that supplier S5 has status 30 until supplier S5 supplies some part; we can’t delete the shipment for supplier S3 without losing the fact that supplier S3 has status 30; and we can’t change the status in one tuple for a given supplier, say supplier S1, without changing it in all of them. The obvious decomposition is into relvars with headings {SNO,STATUS} and {SNO,PNO,QTY}; it’s also obvious that this decomposition avoids the anomalies. Note: It’s worth pointing out in passing that the insertion and deletion anomalies are caused by the fact that the design is logically incorrect, whereas the modification anomaly is caused by the fact that it’s redundant (see Exercise 3.3).

3.2 Let the heading of r be partitioned into sets of attributes X, Y, and Z, and let the projections r1 and r2 be on {X,Y} and {Y,Z}, respectively. (X, Y, and Z are disjoint by definition.) Now let (x,y,z) be a tuple of r; then (x,y) and (y,z) are tuples of r1 and r2, respectively, and so (x,y,z) is a tuple in the join of r1 and r2. Subsidiary exercise: What happens to the foregoing proof if the set Y is empty?

3.3 The two purposes (correcting an incorrect design and reducing redundancy) are explained in the body of the chapter. As for whether you think the point is widely understood: Well, only you can answer this question, but speaking for myself I have to say I don’t think it is.

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

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