Im getting an error in my SQL that says that I've haven't declared a column when I already have in my count..
ERROR: Invalid column name 'counting'.
ideas and ways round the problem?
(SELECT COUNT(schoolID) AS counting FROM Lessons WHERE register.txtSchoolID = Lessons.txtSchoolID ) AS counting
WHERE counting > 1