Hi all,
Seems there's a bug using GROUP BY not on select list on subselects:
SELECT city, AVG(account) FROM customer GROUP BY city HAVING AVG(account) >= ALL (SELECT
city,AVG(account) FROM customer group by city );
ERROR: parser: Subselect has too many or too few fields.
Instead the following does work:
SELECT city, AVG(account) FROM customer GROUP BY city;
city |avg
--------+---
Chicago | 10
Dallas | 60
New York| 50
(3 rows)
SELECT AVG(account) FROM customer GROUP BY city;
avg
---106050
(3 rows)
-Jose'-