having count distinct code example
Example 1: select count of distinct values sql
SELECT COUNT (DISTINCT column-name) FROM table-name
Example 2: count in sql and diff
select (count(city)-count(distinct city)) from station;
SELECT COUNT (DISTINCT column-name) FROM table-name
select (count(city)-count(distinct city)) from station;