Can primary key and foreign key have different names?
I'll answer
Earn 20 gold coins for an accepted answer.20
Earn 20 gold coins for an accepted answer.
40more
40more
Works at the International Monetary Fund, Lives in Washington, D.C., USA.
A foreign key can also have different column names than the primary key. The foreign key and primary key can also have different default values. However, since values in the referenced table must be unique, default values are not much used and are rarely used for columns that are part of a primary key.
2023-05-09 16:08:36
评论(499)
Helpful(122)
Helpful
Helpful(2)

Isabella Lopez
QuesHub.com delivers expert answers and knowledge to you.
A foreign key can also have different column names than the primary key. The foreign key and primary key can also have different default values. However, since values in the referenced table must be unique, default values are not much used and are rarely used for columns that are part of a primary key.