I am having "ORA-00979: not a GROUP BY expression" error in a query using group by and having. Can anybody tell me where the problem is? This is the query.
select DEPTNUM, INSTNAME, DEPTNAME from department
NATURAL join academic
group by DEPTNUM
having count(deptnum) > 10