How a Primary Key can be a composit key? Kindly explain and give some example
A combination of two attributes can be chosen as primary key, in this case it would become composite key.
Example:
Suppose we have an Entity Type EMPLOYEE having attributes Emp ID, Name, Address, Salary, Commission, Joining Date, Designation etc. Now here we can select "Emp ID" as primary key, or we can consider any combination of Emp ID with any other attribute of EMPLOYEE entity type, For example, "Emp ID, Name", "Emp ID, Name, Address" and "Joining Date, Emp ID" and many others all are examples of composite key.
0 Comments
Please add nice comments or answer ....