If the weak entity is ID-dependent on the strong entity, then make the key of the ID-dependent relation
a combination of the foreign key field, and one or more other attributes of the ID-dependent relation.
Another application of ID-dependent entities is in modeling multivalued attributes. For instance, one may
want to provide for multiple addresses for each student; many will have one address during the academic year,
and another during the summer, for instance. In such a case, model an ID-dependent entity called ???Address???,
and create a relation with attributes such as ???Street???, ???City???, ???State???, etc., as well as a foreign key attribute that
will hold values of the primary key for the Student relation.
144 DATABASE [CHAP. 8
With relations created for all entities in the data model, it is time to provide for the relationships in the data
model. For each 1:1 relationship, choose one relation to be the ???parent??? and the other to be the ???child.??? To
implement the relationship, create a foreign key column in the child relation that will be used to associate each
tuple in the child relation with the appropriate tuple in the parent.
If the minimum cardinality on both sides of the 1:1 relationship is 1, it does not matter which relation is
chosen as the parent.
Pages:
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403