Re: making EXPLAIN extensible

From: Sami Imseih <samimseih(at)gmail(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Andrei Lepikhov <lepihov(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Jeff Davis <pgsql(at)j-davis(dot)com>, Thom Brown <thom(at)linux(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: making EXPLAIN extensible
Date: 2025-03-21 13:02:43
Message-ID: CAA5RZ0uYFERQO9XYx9Rc+bVO5WStRSOvK1Bw16qXTNxnCp8xEw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> > explain (query_tree_show range_table) select ..
> > explain (query_tree_show qualification) select ..
> > explain (query_tree_show target_list) select ..
>
> But why would those options be exclusive of each other? Surely you
> could want more than one of those things, which suggests that separate
> options are better.

Yeah, that's a valid point. I guess I was thinking that if we ever
decide to have
an option for every part of the query tree, we will end up with many options
(a half dozen options or so), but not being able to support
"give me these 2 parts only" is not ideal either.

> EXPLAIN doesn't, but that quickly gets into (a) speculation about what
> people actually want to see and/or

Correct. This is why these hooks are useful and people can just
write whatever is useful to them, or if there is a convincing reason,
it can be added into pg_overexplain overtime.

overall this LGTM, and I don't really have other comments.

--
Sami Imseih
Amazon Web Services (AWS)

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ashutosh Bapat 2025-03-21 13:09:11 Re: Test to dump and restore objects left behind by regression
Previous Message vignesh C 2025-03-21 12:45:38 Re: Test to dump and restore objects left behind by regression