About
The project operator is a relational operator that keeps:
- only a set of columns (in other words eliminates the others).
- or delete attributes not in the projection list
It chooses a subset of the columns in the table.
Articles Related
Visualisation
select vs projection.
Notation
<MATH> \begin{array}{c} \LARGE \Pi_{A_1,\,A_2,\,\dots} (R) \\ \\ \LARGE \Pi_{col_1,\,col_2,\, \dots} (Table) \end{array} </MATH>
Type
Set
A set projection is equivalent to a distinct because a set does not allow duplicate.
Sql equivalent:
select distinct col1 from table
Bag
A bag projection has no distinct because it allows duplicate.
Sql equivalent:
select col1 from table