How to set up Primary Keys in a Relation?
问题 I wish to know how to correctly set up Primary Keys in a Relation . E.g. we have ER-diagram which contain elements: Key attributes Weak key attributes Identifying relationships Associative entities In order to translate it into Relational Model we should do some tricks. All elements above deal with Primary Keys of relations but they all are Natural Keys - so we can leave them as is or replace with Surrogate Keys . Consider some cases. Case 1 Key Attribute is a name - so it must be of type