Re: Incomplete Explain for delete

From: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Ghislain ROUVIGNAC <ghr(at)sylob(dot)com>, "pgsql-bugs(at)postgresql(dot)org" <pgsql-bugs(at)postgresql(dot)org>
Subject: Re: Incomplete Explain for delete
Date: 2015-06-22 16:41:28
Message-ID: CAKFQuwZZfAaR17pPDZUthDHd9yQdvA+SXTy+0MRaozRME9QqmA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On Mon, Jun 22, 2015 at 12:19 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> "David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> > On Mon, Jun 22, 2015 at 11:47 AM, Ghislain ROUVIGNAC <ghr(at)sylob(dot)com>
> wrote:
> >> So I think explain needs an improvement as it does not show the real
> plan
> >> used when running the query.
>
> > The underlying limitation here is that the planner does not concern
> itself
> > with triggers.
>
> > ​There is definitely room for improvement here but this complaint by
> itself
> > is not particularly influential to me.​ The black-box nature of
> functions
> > makes anything more detailed than "this table has triggers" difficult -
> > though maybe FK check triggers could be special-cased.
>
> Well, even if EXPLAIN special-cased FK triggers, it would have a hard time
> seeing the plan used for the queries done inside the triggers.
> ​
>

​Except that the query inside the trigger is known to system - the fact it
is wrapped in a trigger is an implementation detail that could, in theory,
be bypassed in order to facilitate a more meaningful explain output.

​David J.​

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message martin.kevin 2015-06-22 17:34:35 BUG #13461: Error message appears to use incorrect values
Previous Message Tom Lane 2015-06-22 16:19:48 Re: Incomplete Explain for delete