Home Exercise 1 (Relational Algebra)

advertisement
Home Exercise 1 (Relational Algebra)
CSE4020 (Databases)
Points: 10
Due: 2/11/02 in class
Spring 2002
From: Text book’s example relations in pages 80-81
Convert the following English queries into relational algebraic queries using
appropriate operators. You may optionally print the output of such queries,
particularly the intermediate results from the question 2.
Do not forget to write your name legibly on top (not SS#)
1. Find all staff-members’ sex, last names, and first names.
[pts 2]
2. Find the sex, last names and first names of all the staff members who work in the
Branch with brnachNo ‘B003’ and whose position is not ‘Assistant’, using only the 
and the  operators.
[pts 4]
3. Do the same query as above using the Join and other operators.
[pts 4]
[Apparently, the question 3 is wrong. You receive full grade by finding the mistake, and
then, by preparing an English query and writing a corresponding Relational-algebraic
query that involves the Join operation on the two tables Staff and Branch.]
Download