Re: Aggregate and many LEFT JOIN

Поиск
Список
Период
Сортировка
От Jeff Janes
Тема Re: Aggregate and many LEFT JOIN
Дата
Msg-id CAMkU=1yOtT4xA4SfuPdEqKxcFPNwjXByC5a6f=Tua__yZkAVAQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Aggregate and many LEFT JOIN  (kimaidou <kimaidou@gmail.com>)
Список pgsql-performance
On Mon, Feb 25, 2019 at 3:54 AM kimaidou <kimaidou@gmail.com> wrote:
 
Wich strikes me is that if I try to simplify it a lot, removing all data but the main table (occtax.observation) primary key cd_nom and aggregate, the query plan should be able tu use the cd_nom index for sorting and provide better query plan (hash aggregate), but it does not seems so :

HashAggregate doesn't support aggregates with DISTINCT.  I don't think there is any reason it can't, it is just that no one has gotten around to it.

Aggregates with DISTINCT also kill your ability to get parallel queries.

Cheers,

Jeff

В списке pgsql-performance по дате отправления:

Предыдущее
От: Justin Pryzby
Дата:
Сообщение: Re: Aggregate and many LEFT JOIN
Следующее
От: Michael Lewis
Дата:
Сообщение: Re: Query slow for new participants