232 views

1 Answer

2 votes
2 votes
$R(PQ)$

$P$ is Foreign Key and  $Q$ is Primary key. It means $values \space of \space(P)\subseteq values \space of \space(Q)$.

$P$ is first attribute in tuple and $Q$ is second atribute in Tuple.

Now,

$ \color{Red}{Option\space1}$ : $P(b_1,b_1,b_0,b_3)$ and $Q(b_1,b_2,b_3,b_4)$.

Here  $b_0$ is not present in $Q$.

$ \color{Green}{Option\space2}$ : $P(b_2,b_1,NULL,b_3)$ and $Q(b_1,b_2,b_3,b_4)$.

YES $values \space of \space(P)\subseteq values \space of \space(Q)$.

$ \color{Red}{Option\space3}$ :  $P(b_2,b_1,b_2,b_3)$ and $Q(NULL,b_2,b_3,b_4)$.

Since $Q$ is Primary Key it can’t have $NULL$ value.

$ \color{Red}{Option\space4}$ :  $P(b_2,b_1,b_4,b_3)$ and $Q(b_1,b_2,b_1,b_4)$.

Here $b_3$ is not present in $Q$.

Related questions

2 votes
2 votes
1 answer
2
1 votes
1 votes
2 answers
4
monty asked Nov 19, 2018
630 views