On Tue, Oct 21, 2014 at 11:50 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Marco Di Cesare <Marco.DiCesare@pointclickcare.com> writes:
>> COUNT(DISTINCT "foxtrot_india"."bravo_romeo")
>
> Ah. That explains why the planner doesn't want to use a hash aggregation
> step --- DISTINCT aggregates aren't supported with those.
yup. With this query, the planner statistics are pretty good for the
most part. Considering that the query is generated and amount of data
is significant the runtime isn't too bad. The query could be
rewritten to support a hash aggregate...
merlin