Week 3 Flashcards
What does a weak entity set reduce to in the relational schema?
A schema that incldues the foreign key column for the primary key of the identifying entity set
How is a many to many relationship set represented in a schema?
With a schema with attributes for the primary keys of the two participating entity sets
How are many-to-one and one-to-many relationship sets represented in the schema?
By adding a foreign key attribute to the side whose entities can only participate once in the relationship set
What kind of relationship set doesn’t require a schema?
An identifying relationship set
How are multivalued attributes represented in a schema?
By creating a separate relation with each value of the multivalued attribute mapping to a separate tuple in this new schema
What are the two approaches for how to deal with generalisation in relational schema?
<ul>
<li>Form a schema for the superclass with a foreign key to the superclass in each of the subclass schemas</li>
<li>Form a schema for each lower level set with all inherited attributes</li>
</ul>
What are the drawbacks of forming a schema for the superclass and having all the subclasses have a foreign key to that?
Getting information is harder, requires accessing information about two relations
What are the drawbacks of having the information stored at each level of the inheritance in the super and sub classes?
Data can be stored redundantly if inheritance is not total
What are some problems that can occur if data redundancy is present in the database?
<ul> <li>Insert anamolies</li> <li>Update anamolies</li> <li>Delete anamolies</li> </ul>
Describe what it means for B to be functionally dependent on A (A->B)
If each possible value of A is associated with exactly one value of B
If A->B then what are A and B?
A - determinant
B - dependent set
What are functional dependencies the property of instead of instances?
Schemas
Define a trivial functional dependency
If the dependent set is a subset of the determinant
Define a partial functional dependency
If the dependent set is functionally dependent on a strict subset of the determinant
(you can remove an attribute from the determinant and the dependency still exists)
Define a full functional dependency
If the dependent set is functionally dependent on the determiner but not on any strict subset of determiner
(you can’t remove an attribute from the determinant and the depedenceny will still exist)