Re: generic options for explain - Mailing list pgsql-hackers

From Greg Stark
Subject Re: generic options for explain
Date
Msg-id 4136ffa0905270444o7c478b9dh98f057da8c43fc90@mail.gmail.com
Whole thread Raw
In response to Re: generic options for explain  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
Responses Re: generic options for explain  ("Kevin Grittner" <Kevin.Grittner@wicourts.gov>)
List pgsql-hackers
On Wed, May 27, 2009 at 1:30 AM, Kevin Grittner
<Kevin.Grittner@wicourts.gov> wrote:
> The big plus of the current technique is that it is so convenient to
> Ctrl+C something which is running too long, arrow up, hit Home, and
> put the EXPLAIN word in front.  Turning the query into a character
> string literal and feeding it to a function would be a big step
> backward.
>
> A big down side of the current technique is that you can't get both
> the results of a SELECT and its plan.  I haven't seen any discussion
> here about emitting the EXPLAIN output through some INFO messages or
> some such, and letting the query return its normal results, but I feel
> that would be a significant improvement, if it that be done.

Would something like this address both of your issues?

http://article.gmane.org/gmane.comp.db.postgresql.devel.patches/21614/match=siginfo

It let you hit a control character while the query was running to view
the explain analyze for the results so far. The query kept running and
you could request further updates whenever you wanted.

--
greg


pgsql-hackers by date:

Previous
From: "Markus Wanner"
Date:
Subject: Re: PostgreSQL Developer meeting minutes up
Next
From: Pavel Stehule
Date:
Subject: replace plpgsql_dstring by StringInfo