Engineering Questions with Answers - Multiple Choice Questions

# MCQs on Keys

1 - Question

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

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

2 - Question

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

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

3 - Question

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

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.

4 - Question

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

Explanation: Key is the constraint which specifies uniqueness.

5 - Question

Which one of the following attribute can be taken as a primary key?
a) Name
b) Street
c) Id
d) Department

Explanation: The attributes name, street and department can repeat for some tuples. But the id attribute has to be unique. So it forms a primary key.

6 - Question

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

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

7 - Question

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) Primary
c) Super
d) Sub

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

8 - Question

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) Referential relation
b) Referencing relation
c) Referenced relation
d) Referred relation

Explanation: None.

9 - Question

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

Explanation: None.

10 - Question

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) Referencing
c) Specific
d) Primary