Relational Algebra & Bag Semantics

R                   S 
-------------       ---------
| A | B | C |       | C | D |
-------------       ---------
| 1 | 1 | 2 |       | 4 | 2 |
| 1 | 1 | 2 |       | 4 | 2 |
| 1 | 2 | 3 |       | 2 | 1 |
| 1 | 2 | 3 |       | 2 | 1 |
| 1 | 2 | 3 |       | 2 | 6 |
| 1 | 4 | 1 |       | 3 | 2 |
| 1 | 5 | 1 |       ---------
-------------

Consider the relations R and S shown above. Let π*, σ*, ∩*, ∪*, −*, ×* denote the bag semantic versions of the relational algebra (RA) operators. Computer the results of the following queries.

  1. ( πC(R)) ∪ (πC(S))

  2. ( π*C(R)) ∪**C(S))

  3. δ ( π*C(R) )

  4. γB,C,Count(B,C) → E R

  5. τD(S)

  6. π*A → F, B2+C → G (R)

  7. R ⋈*L S

  8. R ⋈*R S