Foreign Key attribute - Definition - Database

Q.  An attribute or combination of attributes in one table whose values must either match the primary key in another table or be null is called __________.

- Published on 19 Oct 15

a. Secondary Key
b. Super key
c. Candidate Key
d. Foreign Key

ANSWER: Foreign Key
 

    Discussion

  • Nirja Shah   -Posted on 30 Oct 15
    - There are various types of keys:

    Superkey
    - Any key that uniquely identifies the relation.
    - It is an attribute (or set of attributes) that uniquely identifies each tuple in the table.

    Candidate key
    - It is a superkey which is not composed of attributes which themselves are superkeys.

    Primary key
    - It is defined as a candidate key which has been selected to uniquely identify all other attributes values in any given row.
    - Cannot contain null values.

    Secondary key
    - It is an attribute (or combination of attributes) which is used strictly for data retrieval purposes."

    Foreign key
    - It is an attribute (or combination of attributes) where in one table whose values must either match the primary key in another table or be null.

Post your comment / Share knowledge


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)