Skills101
← Tech dictionary

Databases & SQL

What is Foreign key?

A foreign key is a column that refers to the primary key of another table, enforcing that the referenced row exists (referential integrity).

Example

enrollment.student_id references student.id.

Learn it properlyDBMS & SQL tutorials — free, with diagrams, quizzes and a certificate

Related terms