Projection keeps selected columns and deduplicates the resulting row set.
highlighted = computed this step
Projection chooses columns
Projection keeps named columns in the requested order. Because the result is still a set, duplicate projected rows collapse. Note: the diagrams show when that collapse happens.
π chooses columns
Projection can deduplicate
The input row count is 3 and the recomputed output row count is 2. Note: duplicate projected values collapse because the output is a set.
in=3,out=2
set algebra not SQL bag/NULL, tiny finite tables, no product/perf claims
Projection may keep cardinality
The contrast projection has input row count 3 and recomputed output row count 3. Note: no collapse occurs when every projected value remains distinct.
in=3,out=3
set algebra not SQL bag/NULL, tiny finite tables, no product/perf claims
Summary
Projection changes arity and may change cardinality after deduplication. Note: SQL can preserve duplicates in ordinary query results; that bag boundary is for the next book.