From 9aa491abbf07ca8385a429385be8d68517384fdf Mon Sep 17 00:00:00 2001 From: Alvaro Herrera Date: Mon, 15 Mar 2021 18:33:03 -0300 Subject: Add libpq pipeline mode support to pgbench MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit New metacommands \startpipeline and \endpipeline allow the user to run queries in libpq pipeline mode. Author: Daniel Vérité Reviewed-by: Álvaro Herrera Discussion: https://postgr.es/m/b4e34135-2bd9-4b8a-94ca-27d760da26d7@manitou-mail.org --- doc/src/sgml/ref/pgbench.sgml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'doc/src') diff --git a/doc/src/sgml/ref/pgbench.sgml b/doc/src/sgml/ref/pgbench.sgml index 299d93b2419..50cf22ba6ba 100644 --- a/doc/src/sgml/ref/pgbench.sgml +++ b/doc/src/sgml/ref/pgbench.sgml @@ -1110,6 +1110,12 @@ pgbench options d row, the last value is kept. + + \gset and \aset cannot be used in + pipeline mode, since the query results are not yet available by the time + the commands would need them. + + The following example puts the final account balance from the first query into variable abalance, and fills variables @@ -1270,6 +1276,22 @@ SELECT 4 AS four \; SELECT 5 AS five \aset + + + \startpipeline + \endpipeline + + + + These commands delimit the start and end of a pipeline of SQL + statements. In pipeline mode, statements are sent to the server + without waiting for the results of previous statements. See + for more details. + Pipeline mode requires the use of extended query protocol. + + + + -- cgit v1.2.3