Re: psql - add SHOW_ALL_RESULTS option

From: Fabien COELHO <coelho(at)cri(dot)ensmp(dot)fr>
To: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
Cc: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: psql - add SHOW_ALL_RESULTS option
Date: 2021-07-22 14:49:30
Message-ID: alpine.DEB.2.22.394.2107221632310.25741@pseudo
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Hello,

> Minimally for PSQL_WATCH_PAGER, the pager should exit after some time, but
> before it has to repeat data reading. Elsewhere the psql will hang.

Sure. The "pager.pl" script I sent exits after reading a few lines.

> can be solution to use special mode for psql, when psql will do write to
> logfile and redirect to file instead using any (simplified) pager?

I do not want a special psql mode, I just would like "make check" to tell
me if I broke the PSQL_WATCH_PAGER feature after reworking the
multi-results patch.

> Theoretically, there is nothing special on usage of pager, and just you can
> test redirecting to file.

I do not follow. For what I seen the watch pager feature is somehow a
little different, and I'd like to be sure I'm not breaking anything.

For your information, pspg does not seem to like being fed two results

sh> PSQL_WATCH_PAGER="pspg --stream"
psql> SELECT NOW() \; SELECT RANDOM() \watch 1

The first table is shown, the second seems ignored.

--
Fabien.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2021-07-22 14:56:56 pg_amcheck: Fix block number parsing on command line
Previous Message Dilip Kumar 2021-07-22 14:35:53 Re: row filtering for logical replication