IT lexicon Database Foreign key

Foreign key

Database På svenska → Updated: 2026-05-23

A column that references a primary key in another table — builds the relationship between tables.

In the orders table: user_id references users.id. The database can enforce integrity (ON DELETE CASCADE, RESTRICT). Many modern microservice architectures drop FKs for flexibility — controversially.

← Back to the lexicon