From d0d649e91685081e6c5334d6d01ab4cd735b397d Mon Sep 17 00:00:00 2001 From: Melanie Plageman Date: Tue, 11 Feb 2025 16:51:28 -0500 Subject: Limit pgbench COPY FREEZE to ordinary relations MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit pgbench client-side data generation uses COPY FREEZE to load data for most tables. COPY FREEZE isn't supported for partitioned tables and since pgbench only supports partitioning pgbench_accounts, pgbench used a hard-coded check to skip COPY FREEZE and use plain COPY for a partitioned pgbench_accounts. If the user has manually partitioned one of the other pgbench tables, this causes client-side data generation to error out with: ERROR: cannot perform COPY FREEZE on a partitioned table Fix this by limiting COPY FREEZE to ordinary tables (RELKIND_RELATION). Author: Sergey Tatarintsev Reviewed-by: Álvaro Herrera Discussion: https://postgr.es/m/flat/97f55fca-8a7b-4da8-b413-7d1c57010676%40postgrespro.ru --- doc/src/sgml/ref/pgbench.sgml | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'doc/src') diff --git a/doc/src/sgml/ref/pgbench.sgml b/doc/src/sgml/ref/pgbench.sgml index 46240e3f725..3f488b44d7b 100644 --- a/doc/src/sgml/ref/pgbench.sgml +++ b/doc/src/sgml/ref/pgbench.sgml @@ -231,11 +231,10 @@ pgbench options d sent to the server. This uses the client/server bandwidth extensively through a COPY. pgbench uses the option - with version 14 or later - of PostgreSQL to speed up - subsequent VACUUM, except on the - pgbench_accounts table if partitions are - enabled. Using g causes logging to + to load data into ordinary (non-partition) tables with version 14 + or later of PostgreSQL to speed up + subsequent VACUUM. + Using g causes logging to print one message every 100,000 rows while generating data for all tables. -- cgit v1.2.3