Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6a2l-0000fP-DJ for pgsql-hackers@arkaria.postgresql.org; Thu, 22 Jul 2021 14:51:23 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1m6a2E-0005IR-TR for pgsql-hackers@arkaria.postgresql.org; Thu, 22 Jul 2021 14:50:50 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6a1z-00016w-4X for pgsql-hackers@lists.postgresql.org; Thu, 22 Jul 2021 14:50:35 +0000 Received: from sfr-1.cri.mines-paristech.fr ([77.158.180.225] helo=smtp.cri.ensmp.fr) by magus.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1m6a0z-0000fD-0g for pgsql-hackers@lists.postgresql.org; Thu, 22 Jul 2021 14:49:35 +0000 Received: from pseudo (ip-160.net-81-220-45.lyon.rev.numericable.fr [81.220.45.160]) by smtp.cri.ensmp.fr (Postfix) with ESMTPSA id 067F5C0024; Thu, 22 Jul 2021 16:51:36 +0200 (CEST) Date: Thu, 22 Jul 2021 16:49:30 +0200 (CEST) From: Fabien COELHO X-X-Sender: fabien@pseudo To: Pavel Stehule cc: Peter Eisentraut , "pgsql-hackers@lists.postgresql.org" Subject: Re: psql - add SHOW_ALL_RESULTS option In-Reply-To: Message-ID: References: <69C0B369-570C-4524-8EE4-BCCACECB6BEE@amazon.com> <20210412193301.GA11204@alvherre.pgsql> <3738387.1618451507@sss.pgh.pa.us> <451a2111-3757-c511-9413-8f8af531a167@enterprisedb.com> <18c78a01-4a34-9dd4-f78b-6860f1420c8e@enterprisedb.com> User-Agent: Alpine 2.22 (DEB 394 2020-01-19) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII; format=flowed List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk 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.