What is the relationship between the foreign key and primary key?

What is the relationship between the foreign key and primary key? Each correct answer represents a
complete solution. Choose all that apply.

What is the relationship between the foreign key and primary key? Each correct answer represents a
complete solution. Choose all that apply.

A.
A foreign key constraint works in conjunction with a primary key constraint to enforce
referential integrity among related entities.

B.
A foreign key ties attribute(s) of an entity to the primary key of another entity, for the purpose
of creating a dependency.

C.
There is no relationship between a primary key and a foreign key.

D.
A foreign key and a primary key create a link between two entities.

Explanation:
A foreign key ties attribute(s) of an entity to the primary key of another entity, for the purpose of
creating a dependency. It is used to
establish and enforce a relationship between data in two tables. A relationship between two tables
is created by adding a column or columns
holding the primary key values of the primary table to the related table. This column becomes a
foreign key in the second table. You can
create a foreign key by defining a FOREIGN KEY constraint, when you create or alter a table.



Leave a Reply 0

Your email address will not be published. Required fields are marked *