For database related videos, please subscribe channel
/ @datagurunaval
A foreign key is a set of attributes in a table that refers to the primary key of another table.
The FOREIGN KEY constraint is used to prevent actions that would destroy links between tables.
The table with the foreign key is called the child table, and the table with the primary key is called the referenced or parent table.