Composite Key in DBMS

Rumman Ansari   Software Engineer   2023-03-23   6054 Share
☰ Table of Contents

Table of Content:


Key that consists of two or more attributes that uniquely identify any record in a table is called Composite key. But the attributes which together form the Composite key are not a key independentely or individually.

In the above picture we have a Score table which stores the marks scored by a student in a particular subject.

In this table student_id and subject_id together will form the primary key, hence it is a composite key.