GATE / CS ARCHIVE

GATE CSE 2014 SET 2 / QUESTION 22

GATE CSE 2014 Set 2 Q22

Database Management Systems · Functional Dependencies & Keys · Full GATE CSE 2014 Set 2 paper

GATE 2014 Set 2, Q22 1 mark · NAT
Report issue

Functional Dependencies & Keys

Question 22, GATE 2014: STUDENTS has columns StudentID, StudentName, StudentEmail, StudentAge, CPI and rows (2345,Shankar,shankar@math,X,9.4), (1287,Swati,swati@ee,19,9.5), (7853,Shankar,shankar@cse,19,9.4), (9876,Swati,swati@mech,18,9.3), (8765,Ganesh,ganesh@civil,19,8.7). For (StudentName,StudentAge) to be a key of this instance, what value must X NOT equal?
Tap to enlarge
Answer & solution

Official answer: 19

1. Set up the reasoning. Project each row to the proposed key columns. Distinct names cannot collide, so only rows sharing a name need to be compared.

2. Derive the result. The two Shankar rows would have the same(Name, Age) pair if X=19. Other repeated names already have different ages, and neither name nor age alone is unique. Hence X must not equal 19 for the pair to be a key of this instance.

3. Check the interpretation. The two Swati ages already differ. The Shankar ages would coincide at X=19, creating two different rows with the same key pair. Other columns such as unique emails do not repair a collision in the specified pair.

Original paper, page 34 · Answer key