A table could hold duplicate rows. In such a case, to view only unique rows the distinct clause can be used.
The DISTINCT clause allows removing duplicates from the result set. The DISTINCT clause can only be used with select statements.
The DISTINCT clause scans through the values of the column/s specified and displays only unique values from amongst them.
The SELECT DISTINCT * SQL syntax scans through entire rows, and eliminates rows that have exactly the same contents in each column.
SELECT DISTINCT * FROM
Show different types of occupations of the customers by eliminating the repeated occupations
SELECT DISTINCT OCCUP FROM CUST_MSTR;
7 rows selected.