Posted by Marius III on 11/02/04 11:30
Hi there,
I am used to program with Delphi etc...
I get an error on the following query:
SELECT C.CityID, C.Description, COUNT(R.CityID) AS N FROM tblcities C
LEFT OUTER JOIN tblrentalswanted R ON C.CityID = R.CityID LEFT OUTER JOIN
tblprovinces P ON C.ProvinceID = P.ProvinceID WHERE N > 0 GROUP BY C.CityID
ORDER BY C.Description
The error is: "Unknown column in Where clause 'N' ".
It is self explanatory but why can I not do this.
What is the alternative to select all fields where aggregated field is
greater than certain condition?
Thanks alot!
BTW: Hope this newsgroup is suitable for my question.
Navigation:
[Reply to this message]
|