As we learn before, SQL SELECT statement will allow us to call out all the data from particular table. What if we want to select distinct elements?
In SQL, DISTINCT keyword is used to return only distinct (different) values.All we need to do is add the DISTINCT after SELECT.
The SQL Syntax will look like this:
SELECT DISTINCT [COLUMN NAME] FROM [TABLE NAME]
The DISTINCT clause allows you to remove duplicates from the result set.
Let�s say, we want to know departments from GameScores for people who participate.
SQL statement :
SELECT DISTINCT Department FROM GameScores
This SQL statement would return all unique Department from the GameScores table