From: | Souvik Bhattacherjee <kivuosb(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Bruce Momjian <bruce(at)momjian(dot)us>, Thomas Kellerer <spam_eater(at)gmx(dot)net> |
Cc: | "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Is it possible to store the output of EXPLAIN into a table |
Date: | 2019-04-23 23:11:54 |
Message-ID: | CAANrPSfo5EgVpfe02eJRSXtpxUO-rMQkHNja-jFMn+52ac0RwQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Thanks, works fine!
-Souvik
On Mon, Apr 22, 2019 at 12:02 PM Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Souvik Bhattacherjee <kivuosb(at)gmail(dot)com> writes:
> > I was just wondering if it is possible to store the output of EXPLAIN
> into
> > a table.
>
> EXPLAIN won't do that directly, but you could make a plpgsql function
> along the lines of
>
> for t in execute explain ...
> return next t;
>
> (too lazy to check the exact details here, but I believe you can find
> related examples in our regression tests) and then store the function's
> result into a table.
>
> regards, tom lane
>
From | Date | Subject | |
---|---|---|---|
Next Message | Michel Pelletier | 2019-04-24 00:38:06 | Re: Quick hack for fetching the contents of a temp table |
Previous Message | Lewis Shobbrook | 2019-04-23 22:44:10 | Re: pgdg packages removed for 9.3 |