Having built the SQL statement in the previous exercise to show all rows
of the table PARTS (see Advanced
SELECT prototyping: the completed statement (example 1)),
suppose you want to change this to eliminate all but one of each set
of duplicate rows:
- Move the cursor under the word ALL in the generated statement.
- Press Enter. The syntax for the SELECT clause is displayed.
- Move the cursor to the keyword DISTINCT.
- Press Enter. DISTINCT replaces ALL in the built SELECT statement.
The panel shows the completed SELECT statement:
SELECT DISTINCT * FROM PARTS
Related tasks