DISTINCT: Removes duplicate rows from the result, or counts unique values with COUNT(DISTINCT col). DISTINCT removes duplicate rows from a query result. SELECT DISTINCT country FROM customers lists each country once. COUNT(DISTINCT customer_id) counts unique customers instead of orders. It is handy for questions like how many different customers bought something this month, or which cities you deliver to.
If you need DISTINCT to fix duplicates caused by a join, look at the join first. Duplicates often mean a one-to-many relationship you did not account for, and DISTINCT hides the symptom while the query still does extra work. On large tables, DISTINCT can be slow because the database must sort or hash all rows. An index on the column, or a GROUP BY with the information you actually need, is often faster.