SELECT projection happens before duplicate removal.
highlighted = computed this step
Projection before DISTINCT
SELECT chooses the output columns before DISTINCT removes repeats.
project then distinct
Read projected rows
Projection makes 6 projected rows before duplicates are removed.
projected rows=6
DISTINCT examples are tiny finite bag-to-table transforms; this model shows first-seen representatives for deterministic display and does not claim product SQL output ordering.
Only city is kept
The id and status columns are not part of the DISTINCT key in this lesson.
selected columns form key
Summary
DISTINCT compares the projected rows, not the original full input rows.