Is it possible to store the output of EXPLAIN into a table

From: Souvik Bhattacherjee <kivuosb(at)gmail(dot)com>
To: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Is it possible to store the output of EXPLAIN into a table
Date: 2019-04-22 15:27:18
Message-ID: CAANrPSdL9YpU0hqm=YfPUQKHVXrSCVTRO-5QekEDdEmNv5UbEA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I was just wondering if it is possible to store the output of EXPLAIN into
a table.

create temp table mytab as (select * from (explain select * from table1
where attr = 5) t);

Unfortunately, the query above does not work.

Thanks,

-Souvik

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Scot Kreienkamp 2019-04-22 15:30:01 RE: Streaming Replication
Previous Message Adrian Klaver 2019-04-22 14:05:15 Re: cache lookup failed for function 1 on fmgr_info_cxt_security, fmgr.c:184