[HACKERS] auto_explain : log queries with wrong estimation

Поиск
Список
Период
Сортировка
От Adrien Nayrat
Тема [HACKERS] auto_explain : log queries with wrong estimation
Дата
Msg-id 55d18a40-d99f-eccc-7323-62e0806ad7a6@dalibo.com
обсуждение исходный текст
Ответы Re: [HACKERS] auto_explain : log queries with wrong estimation  (Maksim Milyutin <milyutinma@gmail.com>)
Список pgsql-hackers
Hi hackers,


I try to made a patch to auto_explain in order to log queries with wrong estimation.

I compare planned row id : queryDesc->planstate->plan->plan_rows

Vs ntuples : queryDesc->planstate->instrument->ntuples;

If I understand, instrumentation is used only with explain. So my patch works
only with explain (and segfault without).


Is there a simple way to get ntuples?

Attached a naive patch.

Thanks :)

--
Adrien NAYRAT

http://dalibo.com - http://dalibo.org

Вложения

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

Предыдущее
От: Thomas Munro
Дата:
Сообщение: [HACKERS] MCXT_ALLOC_NO_OOM -> DSA_ALLOC_NO_OOM in dsa.c
Следующее
От: Thomas Munro
Дата:
Сообщение: Re: [HACKERS] POC: Sharing record typmods between backends