Professional Documents
Culture Documents
• You’re not allowed to consult your classmates during lab work. (As of course
it won’t go in your benefit)
• To seek any help, consult with the TAs.
• Solve the lab on blank paper and don’t forget to write your roll number
and name.
1. Define Union and Intersection:
a) Return a relation consisting of all the tuples appearing in either or all the relations.
b) Return a relation representing the intersection of the tables below.
4. Find:
Relation A
ID FirstName Last Name Hire Year
S1 Betsy Adams 2008
S2 Ryan Potter 2010
S3 Arnold Elfis 2008
S4 Ryan Potter 2013
Relation B
ID FirstName Last Name Hire Year
S1 Betsy Adams 2008
S2 Ryan Potter 2010
S3 Arnold Elfis 2008
S4 Ryan Potter 2013
S6 Susan Reyna 2009
i) Find A Times B
ii) Find (A TIMES B) where IDA > IDB
iii) Find (A TIMES B) where IDA = IDB
iv) Find (A TIMES B) where IDA < IDB
v) Find A-B
vi) Find B-A