0
To bulid a Sql query to find the total count of all unique enployee number in a table
3 Respuestas
+ 3
SELECT COUNT (DISTINCT column-name)
FROM table-name
Taken from here:
http://www.dofactory.com/sql/select-distinct
+ 1
please explain your questions further. if it is to count all your employee in same table just type "SELECT COUNT(*) AS total FROM tablename";
if there are other users in the table that are not employee. you should have a column that identifies a user as employee u can then write "SELECT COUNT(*) AS total FROM tablename WHERE column_name = identifier";
0
note u can safely omit the AS keyword for brevity