Oleg,
> ERROR: column "query.query" must appear in the GROUP BY clause or be> used in an aggregate function
Apparently the parser thinks you have an aggregate function in there. Do you?
-- --Josh
Josh BerkusAglio Database SolutionsSan Francisco