Integrity Constraints


Q1.

Consider the following tables T1 and T2. In table T1, P is the primary key and Q is the foreign key referencing R in table T2 with ondelete cascade and on-update cascade. In table T2, R is the primary key and S is the foreign key referencing P in table T1 on-delete set NULL and on-update cascade. In order to delete record (3,8) from table T1, the number of additional records that need to be deleted from table T1 is _____.
GateOverflow

Q3.

The following table has two attributes A and C where A is the primary key and C is the foreign key referencing A with on-delete cascade. The set of all tuples that must be additionally deleted to preserve referential integrity when the tuple (2,4) is deleted is:
GateOverflow

Q4.

Let R(a, b, c) and S(d, e, f) be two relations in which d is the foreign key of S that refers to the primary key of R. Consider the following four operations R and S I. Insert into R II. Insert into S III. Delete from R IV. Delete from S Which of the following can cause violation of the referential integrity constraint above?
GateOverflow

Q5.

Let R(a,b,c) and S(d,e,f) be two relations in which d is the foreign key of S that refers to the primary key of R. Consider the following four operations R and S I. Insert into R II. Insert into S III. Delete from R IV. Delete from S Which of the following can cause violation of the referential integrity constraint above?
GateOverflow