Re: display of variables in EXPLAIN VERBOSE - Mailing list pgsql-hackers

From Amit Langote
Subject Re: display of variables in EXPLAIN VERBOSE
Date
Msg-id 44030ba1-8b67-7548-efdd-e0888b198764@lab.ntt.co.jp
Whole thread Raw
In response to Re: display of variables in EXPLAIN VERBOSE  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On 2019/04/23 0:58, Tom Lane wrote:
> BTW, now that I look at this, I think the reason why I didn't make
> tlist printouts pay attention to VERBOSE for this purpose is that
> you don't get them at all if not verbose:
> 
> regression=# explain select * from tt;
>                       QUERY PLAN                      
> ------------------------------------------------------
>  Seq Scan on tt  (cost=0.00..32.60 rows=2260 width=8)
> (1 row)
> 
> So if we were to be rigidly consistent with this point of the docs,
> there would be no way to see a tlist without variable qualification,
> which doesn't really seem that nice.

Hmm yes.  Variables in sort keys, quals, etc., which are shown without
VERBOSE, are qualified only if VERBOSE is specified.  Variables in the
targetlists that are shown only in the VERBOSE output may be displayed
without qualifications, which looks a bit inconsistent.

explain (verbose, costs off) select * from foo where a > 0 order by 1;
          QUERY PLAN
──────────────────────────────
 Sort
   Output: a
   Sort Key: foo.a
   ->  Seq Scan on public.foo
         Output: a
         Filter: (foo.a > 0)
(6 rows)

Maybe, targetlist variables should *always* be qualified given that they
are considered VERBOSE information to begin with?

Thanks,
Amit




pgsql-hackers by date:

Previous
From: Kyotaro HORIGUCHI
Date:
Subject: Re: Regression test PANICs with master-standby setup on samemachine
Next
From: Michael Paquier
Date:
Subject: Re: REINDEX INDEX results in a crash for an index of pg_class since9.6