Re: psql - factor out echo code - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: psql - factor out echo code
Date
Msg-id Y4cKLWjuz0BUK7n9@paquier.xyz
Whole thread Raw
In response to Re: psql - factor out echo code  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: psql - factor out echo code
List pgsql-hackers
On Sun, Jul 24, 2022 at 10:23:39PM +0200, Pavel Stehule wrote:
> I had just one question - with this patch, the format of output of modes
> ECHO ALL and ECHO QUERIES will be different, and that can be a little bit
> messy. On second hand, the prefix --QUERY can be disturbing in echo queries
> mode. It is not a problem in echo all mode, because queries and results are
> mixed together. So in the end, I think the current design can work.
>
> All tests passed, this is trivial patch without impacts on users
>
> I'll mark this patch as ready for committer

Hmm.  The refactoring is worth it as much as the differentiation
between QUERY and INTERNAL QUERY as the same pattern is repeated 5
times.

Now some of the output generated by test_extdepend gets a bit
confusing:
+-- QUERY:
+
+
+-- QUERY:

That's not entirely this patch's fault.  Still that's not really
intuitive to see the output of a query that's just a blank spot..
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Masahiko Sawada
Date:
Subject: Re: [PoC] Improve dead tuple storage for lazy vacuum
Next
From: Daniel Gustafsson
Date:
Subject: Re: pg_dump: Remove "blob" terminology