Computer Science, asked by nazakath3801, 1 year ago

Give an example of foreign key constraint that involves the dept relation. What are the options for enforcing this constraint when a user attempts to delete a dept tuple.

Answers

Answered by arpita8137
5

, when a user attempts to delete a tuple from Dept, we can !also delete all Works tuples that refer to it. !disallow the deletion of the Dept tuple if some Works tuple refers to it. !for every Works tuple that refers to it, set the did field to the did of some (existing) ’default’ department. !for every Works tuple that refers to it, set the did field to null.

Answered by rosoni28
2

Explanation:

foreign key is a column (or columns) that references a column (most often the primary key) of another table. ... For example, say we have two tables, a CUSTOMER table that includes all customer data, and an ORDERS table that includes all customer orders.

thanku

Similar questions