Search
 
SCRIPT & CODE EXAMPLE
 

SQL

select count of distinct values sql

SELECT COUNT (DISTINCT column-name)  FROM table-name
Comment

SQL DISTINCT with COUNT

SELECT COUNT(DISTINCT country)
FROM Customers;
Comment

sql select count distinct

select column_name, count(*) AS count FROM table_name GROUP BY column_name;
Comment

PREVIOUS NEXT
Code Example
Sql :: oracle ora-00054 resource busy 
Sql :: add user mysql wordpress 
Sql :: how to rename column in sql 
Sql :: mysql concatenate columns 
Sql :: Uncaught Error: Cannot use object of type mysqli_result as array 
Sql :: check all database size in gb mysql 
Sql :: access mysql command mac xampp 
Sql :: oracle add datafile to tablespace 
Sql :: ORACLE SHOW AVAILABLE DB LINK 
Sql :: sql current year 
Sql :: désinstaller postgresql linux 
Sql :: add user mysql 
Sql :: stop and start mysql 
Sql :: docker export psql sql 
Sql :: SQL SERVER SELECT BETWEEN DATETIME 
Sql :: sql get count without group by 
Sql :: mysql get random data 
Sql :: show column from sql server 
Sql :: clear a table in mysql 
Sql :: mysql date to string 
Sql :: mysql select and count left join 
Sql :: get top 10 records in oracle 
Sql :: postgres set default value 
Sql :: delete temp table if exists 
Sql :: convert date to dd/mm/yyyy sql 
Sql :: install mysql workbench ubuntu 20.04 
Sql :: postgres copy table from one schema to another 
Sql :: drop view sql 
Sql :: update with inner join postgres 
Sql :: set id count mysql 
ADD CONTENT
Topic
Content
Source link
Name
1+3 =