-
another count problem
When I try to count something and want the results to be displayed that are over 20 i use count(people)>20 but this brings up errors such as group function not allowed here and not a singlegroup group function.
I was just wondering what would be causing those errors?
Thanks in advance.
-
You can't have a column in select statement that has group function like count and another column without any grouping function.
Post your sql statement and I can point out what is causing the problem.
-
An example would be:
select employeeNo, name count(project.project#) "over 20 projects"
from employee, project
where employee.employeeNo=project.employeeNo and count(project.project#)>20;
I want to be able to display the employees with over 20 projects.
Any ideas where I would be going wrong?
-
select employeeNo, name, count(project.project#) "over 20 projects"
from employee, project
where employee.employeeNo=project.employeeNo
group by employeeNo, name
having count(project.project#)>20
-
I seem to have got that working but where I have the count project number instead of displaying say 21 it would display 210.
Any idea why its doing that?