The Projection Operation (cont)
The projection operation needs to:
- scan the entire relation as input
- already seen how to do scanning
- remove unwanted attributes in output tuples
- implementation depends on tuple internal structure
- essentially, make a new tuple with fewer attributes
and where the values may be computed from existing attributes
- eliminate any duplicates produced (if
distinct )
- two approaches: sorting or hashing
|