Database Management System Questions and Answers Part-2

1. Which one of the following cannot be taken as a primary key?
a) Register number
b) Dept_id
c) Id
d) Street

Answer: d
Explanation: Street is the only attribute which can occur more than once.

2. A _________ integrity constraint requires that the values appearing in specified attributes of any tuple in the referencing relation also appear in specified attributes of at least one tuple in the referenced relation.
a) Referential
b) Primary
c) Referencing
d) Specific

Answer: a
Explanation: A relation, say r1, may include among its attributes the primary key of another relation, say r2. This attribute is called a foreign key from r1, referencing r2. The relation r1 is also called the referencing relation of the foreign key dependency, and r2 is called the referenced relation of the foreign key.

3. Which one of the following is a set of one or more attributes taken collectively to uniquely identify a record?
a) Foreign key
b) Super key
c) Sub key
d) Candidate key

Answer: b
Explanation: Super key is the superset of all the keys in a relation.

4. The relation with the attribute which is the primary key is referenced in another relation. The relation which has the attribute as a primary key is called ______________
a) Referencing relation
b) Referred relation
c) Referenced relation
d) Referential relation

Answer: c
Explanation: Referenced relation

5. The subset of a super key is a candidate key under what condition?
a) No proper subset is a super key
b) Subset is a super key
c) All subsets are super keys
d) Each subset is a super key

Answer: a
Explanation: The subset of a set cannot be the same set. Candidate key is a set from a super key which cannot be the whole of the super set.

6. The ______ is the one in which the primary key of one relation is used as a normal attribute in another relation.
a) Referenced relation
b) Referred relation
c) Referencing relation
d) Referential relation

Answer: a
Explanation: Referenced relation

7. A _____ is a property of the entire relation, rather than of the individual tuples in which each tuple is unique.
a) Attribute
b) Fields
c) Rows
d) Key

Answer: d
Explanation: Key is the constraint which specifies uniqueness.

8. Consider attributes ID, CITY and NAME. Which one of this can be considered as a super key?
a) NAME
b) ID
c) CITY, ID
d) CITY

Answer: b
Explanation: Here the id is the only attribute which can be taken as a key. Other attributes are not uniquely identified.

9. Department (dept name, building, budget) and Employee (employee_id, name, dept name, salary) Here the dept_name attribute appears in both the relations. Here using common attributes in relation schema is one way of relating ___________ relations.
a) Attributes of distinct
b) Attributes of common
c) Tuple of distinct
d) Tuple of common

Answer: c
Explanation: Here the relations are connected by the common attributes.

10. An attribute in a relation is a foreign key if the _______ key from one relation is used as an attribute in that relation.
a) Candidate
b) Super
c) Sub
d) Primary

Answer: d
Explanation: The primary key has to be referred in the other relation to form a foreign key in that relation.