TATA Consultancy Services Interview Question
Dev Leads Dev LeadsCountry: India
Interview Type: Phone Interview
Composite Key :
A composite key is a combination of more than one column to identify a unique row in a table.
Exp : EmpID, EmailID, SSN in Employee table and project ID in project table .
if EmpID and project id are put in projectionHours table then combination of empid and project ID called as composite key because combination of these two act as primary key in projectionHours table.
Candidate Key:
All keys in a table that become unique called as candidate key.
Exp : EmpID , EmailID and SSN all will be always unique for any employee in that case all these three columns called as candidate keys.
All the combination of attributes which are used to uniquely identify any record called composite key.
- Amit kumar August 15, 2014minimum no of attributes used for uniquely identify any entity called candidate key