Start networking and exchanging professional insights

Register now or log in to join your professional community.

Follow

What is a foreign key, and what is it used for?

user-image
Question added by Emad Mohammed said abdalla , ERP & IT Software, operation general manager . , AL DOHA Company
Date Posted: 2014/12/20
Emad Mohammed said abdalla
by Emad Mohammed said abdalla , ERP & IT Software, operation general manager . , AL DOHA Company

A foreign key is used to establish relationships among relations in the relational model. Technically, a foreign key is a column (or columns) appearing in one relation that is (are) the primary key of another table. Although there may be exceptions, the values in the foreign key columns usually must correspond to values existing in the set of primary key values. This correspondence requirement is created in a database using a referential integrity constraint on the foreign key.

More Questions Like This