Database Model:
Important note: this is a wrong solution:
because:
Employee ⋈dno=dnumber Department
Now we can apply the selection conditions:
σdname='Research' ∧ salary > 50000 ( Employee ⋈dno=dnumber Department )
Finally, we project out the attributes that we need:
πfn,ln ( σdname='Res' ∧ sal > 50000 ( Emp ⋈dno=dnumber Dept ) )
This solution is wrong:
Example that illustrates why the query is wrong:
Notice that:
(i.e., "the kid is not mine !!!)
(because there is a dependent that does not belong to him/her !!!)
The correct solution is: