What is a FOREIGN KEY ?

A foreign key is a relationship between two tables in a database.It acts as a cross-reference between tables because it references the primary key of another table, thereby establishing a link between them.
 
Last edited:
A foreign key is a key used to link two tables together. This is sometimes also called as a referencing key.

A Foreign Key is a column or a combination of columns whose values match a Primary Key in a different table.

The relationship between 2 tables matches the Primary Key in one of the tables with a Foreign Key in the second table.
 
Back
Top