I have a small list of employees, and how much units they finished a given day. But I have duplicate values, because they have to place multiple components. List looks something like this:
| Employee | SerialNumber | ACTION |
|---|---|---|
| x | 111 | PLACE |
| x | 111 | PLACE |
| x | 222 | PLACE |
| y | 333 | PLACE |
| y | 333 | PLACE |
| y | 444 | PLACE |
I would like to get a query, to show the amount of units the employee made without duplicates, so like this:
X - 2
Y - 2
I made a query for it in MS Access:
SELECT Operator, COUNT(DISTINCT SerialNumber) as "QTY"
FROM Database
WHERE ACTION="PLACE"
GROUP BY Operator;
But it gives me the following error:
Syntax error (missing operator) in query expression 'COUNT(DISCTINCT SerialNumber)'.