retagged by
9,274 views
21 votes
21 votes

Consider the following statements $S1$ and $S2$ about the relational data model:

  • $S1$: A relation scheme can have at most one foreign key.
  • $S2$: A foreign key in a relation scheme $R$ cannot be used to refer to tuples of $R.$

Which one of the following choices is correct?

  1. Both $S1$ and $S2$ are true
  2. $S1$ is true and $S2$ is false
  3. $S1$ is false and $S2$ is true
  4. Both $S1$ and $S2$ are false
retagged by

6 Answers

Best answer
28 votes
28 votes
Both $S1$ and $S2$ are FALSE.

In a relation scheme multiple foreign attributes can be present referring to primary keys of other relation schemes. A typical example is an $\text{EXAM_RESULTS(sid,eid,marks)}$ scheme where $\text{sid}$ and $\text{eid}$ are foreign keys referring to the primary keys in $\text{STUDENT}$ and $\text{EXAM}$ schemes respectively.

$S2$ is FALSE because a foreign key can refer to the same scheme (self-referencing foreign key). A typical example is an $\text{EMPLOYEE(eid, mid, $\ldots$)}$ scheme where $\text{mid}$ is the Manager ID referring to the primary key $\text{eid}$ of the same scheme.
selected by
1 votes
1 votes
S1 is false because there is no rule that a relation schema can have atmost one foreign key in minium. It can have more than 1 foreign key as well.

S2 is false because in a relation a foreign key cant identify a tuple uniquely. so they cant be used to refer to a tuple of R

 

answer is D both are false
Answer:

Related questions