Re: [FEATURE PATCH] pg_stat_statements with plans (v02)

Поиск
Список
Период
Сортировка
От Thomas Munro
Тема Re: [FEATURE PATCH] pg_stat_statements with plans (v02)
Дата
Msg-id CAEepm=1uzE8tK4cv_0fnQTK_DnDgG7267LqmQnHL979ycKrRFA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: [FEATURE PATCH] pg_stat_statements with plans (v02)  (Julian Markwort <julian.markwort@uni-muenster.de>)
Ответы Re: [FEATURE PATCH] pg_stat_statements with plans (v02)  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
On Sat, Apr 7, 2018 at 1:03 AM, Julian Markwort
<julian.markwort@uni-muenster.de> wrote:
> I've created a draft patch that provides access to plans in a view called pg_stat_statements_plans.
> There is no column that indicates whether the plan is "good" or "bad", because that is evident from the execution
timeof both plans and because that would require some kind of plan_type for all plans that might be stored in future
versions.
>
> Please take it for a spin and tell me, whether the layout and handling of the view make sense to you.

I realise this is probably WIP, but for what it's worth here's some
feedback from my patch testing robot:

+ +INFINITY,

That ^ is from C99 math.h, and so we don't currently expect compilers
to have it (until such time as we decide to pull the trigger and
switch to C99, as discussed in a nearby thread):

  contrib/pg_stat_statements/pg_stat_statements.c(482): error C2065:
'INFINITY' : undeclared identifier
[C:\projects\postgresql\pg_stat_statements.vcxproj]
5826

Maybe get_float8_infinity()?

+ for(int j = 0; j < numPlans; j++)

Can't declare a new variable here in C89.

+ pgssPlan *planArray[numPlans];

Can't use variable length arrays in C89.

-- 
Thomas Munro
http://www.enterprisedb.com


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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: Temporary tables prevent autovacuum, leading to XID wraparound
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: [PATCH] Add regress test for pg_read_all_stats role