Re: Add Pipelining support in psql - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Add Pipelining support in psql
Date
Msg-id Z9oIRs2c7SCTNmfi@paquier.xyz
Whole thread Raw
In response to Re: Add Pipelining support in psql  ("Daniel Verite" <daniel@manitou-mail.org>)
List pgsql-hackers
On Tue, Mar 18, 2025 at 10:36:28AM +0100, Daniel Verite wrote:
> It's actually possible to use parameters
>
> \startpipeline
> \bind 'foo'
> select $1;
> \endpipeline
>
>  ?column?
> ----------
>  foo
> (1 row)
>
> I suspect there's a misunderstanding that \bind can only be placed
> after the query, because it's always written like that in the regression
> tests, and in the documentation.
> But that's just a notational preference.

Nice trick, unrelated to pipelines.  I don't think that we have
anything testing this specific pattern for \bind.  At quick glance all
our test use \bind at the end of a query string.  Perhaps we should?
--
Michael

Attachment

pgsql-hackers by date:

Previous
From: Gregory Smith
Date:
Subject: Re: Increase default maintenance_io_concurrency to 16
Next
From: "David G. Johnston"
Date:
Subject: Re: add function argument name to substring and substr