Title: Exercises
1Exercises
Reserves
Sailors
Boats
Basic operations Selection ( s ) gives a
subset of rows. Projection ( p ) Deletes
unwanted cols. Cross-product ( ? ) combine two
relations. Set-difference ( ) Tuples in reln.
1, but not in reln. 2. Union ( ?
) Tuples in reln. 1 and in reln. 2.
Additional operations Intersection (?) Tuples
in both relns. Join ( ) like ? but only
keep tuples where common fields equal Division
( / ) tuples from reln 1 with matches in reln
2 Renaming ( ?) Rename columns
Find names of sailors whove reserved boat 103
2Exercises
Reserves
Sailors
Boats
Basic operations Selection ( s ) gives a
subset of rows. Projection ( p ) Deletes
unwanted cols. Cross-product ( ? ) combine two
relations. Set-difference ( ) Tuples in reln.
1, but not in reln. 2. Union ( ?
) Tuples in reln. 1 and in reln. 2.
Additional operations Intersection (?) Tuples
in both relns. Join ( ) like ? but only
keep tuples where common fields equal Division
( / ) tuples from reln 1 with matches in reln
2 Renaming ( ?) Rename columns
Find names of sailors whove reserved a red boat
3Exercises
Reserves
Sailors
Boats
Basic operations Selection ( s ) gives a
subset of rows. Projection ( p ) Deletes
unwanted cols. Cross-product ( ? ) combine two
relations. Set-difference ( ) Tuples in reln.
1, but not in reln. 2. Union ( ?
) Tuples in reln. 1 and in reln. 2.
Additional operations Intersection (?) Tuples
in both relns. Join ( ) like ? but only
keep tuples where common fields equal Division
( / ) tuples from reln 1 with matches in reln
2 Renaming ( ?) Rename columns
Find sailors whove reserved a red or a green boat
4Exercises
Reserves
Sailors
Boats
Basic operations Selection ( s ) gives a
subset of rows. Projection ( p ) Deletes
unwanted cols. Cross-product ( ? ) combine two
relations. Set-difference ( ) Tuples in reln.
1, but not in reln. 2. Union ( ?
) Tuples in reln. 1 and in reln. 2.
Additional operations Intersection (?) Tuples
in both relns. Join ( ) like ? but only
keep tuples where common fields equal Division
( / ) tuples from reln 1 with matches in reln
2 Renaming ( ?) Rename columns
Find sailors whove reserved a red and a green
boat
5Exercises
Reserves
Sailors
Boats
Basic operations Selection ( s ) gives a
subset of rows. Projection ( p ) Deletes
unwanted cols. Cross-product ( ? ) combine two
relations. Set-difference ( ) Tuples in reln.
1, but not in reln. 2. Union ( ?
) Tuples in reln. 1 and in reln. 2.
Additional operations Intersection (?) Tuples
in both relns. Join ( ) like ? but only
keep tuples where common fields equal Division
( / ) tuples from reln 1 with matches in reln
2 Renaming ( ?) Rename columns
Find the names of sailors whove reserved all
boats