diff options
author | Michael Paquier <michael@paquier.xyz> | 2021-03-09 14:21:03 +0900 |
---|---|---|
committer | Michael Paquier <michael@paquier.xyz> | 2021-03-09 14:21:03 +0900 |
commit | 9d2d45700928d49212fb7ed140feeaebe3a6014f (patch) | |
tree | 88c79348c8b63167cae1cf4636185cc48e24785b /doc/src | |
parent | f9264d1524baa19e4a0528f033681ef16f61b137 (diff) | |
download | postgresql-9d2d45700928d49212fb7ed140feeaebe3a6014f.tar.gz postgresql-9d2d45700928d49212fb7ed140feeaebe3a6014f.zip |
Add support for more progress reporting in COPY
The command (TO or FROM), its type (file, pipe, program or callback),
and the number of tuples excluded by a WHERE clause in COPY FROM are
added to the progress reporting already available.
The column "lines_processed" is renamed to "tuples_processed" to
disambiguate the meaning of this column in the cases of CSV and BINARY
COPY and to be more consistent with the other catalog progress views.
Bump catalog version, again.
Author: Matthias van de Meent
Reviewed-by: Michael Paquier, Justin Pryzby, Bharath Rupireddy, Josef
Šimánek, Tomas Vondra
Discussion: https://postgr.es/m/CAEze2WiOcgdH4aQA8NtZq-4dgvnJzp8PohdeKchPkhMY-jWZXA@mail.gmail.com
Diffstat (limited to 'doc/src')
-rw-r--r-- | doc/src/sgml/monitoring.sgml | 45 |
1 files changed, 40 insertions, 5 deletions
diff --git a/doc/src/sgml/monitoring.sgml b/doc/src/sgml/monitoring.sgml index 53692c0020b..51f73384041 100644 --- a/doc/src/sgml/monitoring.sgml +++ b/doc/src/sgml/monitoring.sgml @@ -6531,8 +6531,33 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS pid, <structfield>relid</structfield> <type>oid</type> </para> <para> - OID of the table on which the <command>COPY</command> command is executed. - It is set to 0 if copying from a <command>SELECT</command> query. + OID of the table on which the <command>COPY</command> command is + executed. It is set to <literal>0</literal> if copying from a + <command>SELECT</command> query. + </para></entry> + </row> + + <row> + <entry role="catalog_table_entry"><para role="column_definition"> + <structfield>command</structfield> <type>text</type> + </para> + <para> + The command that is running: <literal>COPY FROM</literal>, or + <literal>COPY TO</literal>. + </para></entry> + </row> + + <row> + <entry role="catalog_table_entry"><para role="column_definition"> + <structfield>type</structfield> <type>text</type> + </para> + <para> + The io type that the data is read from or written to: + <literal>FILE</literal>, <literal>PROGRAM</literal>, + <literal>PIPE</literal> (for <command>COPY FROM STDIN</command> and + <command>COPY TO STDOUT</command>), or <literal>CALLBACK</literal> + (used for example during the initial table synchronization in + logical replication). </para></entry> </row> @@ -6551,16 +6576,26 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS pid, </para> <para> Size of source file for <command>COPY FROM</command> command in bytes. - It is set to 0 if not available. + It is set to <literal>0</literal> if not available. + </para></entry> + </row> + + <row> + <entry role="catalog_table_entry"><para role="column_definition"> + <structfield>tuples_processed</structfield> <type>bigint</type> + </para> + <para> + Number of tuples already processed by <command>COPY</command> command. </para></entry> </row> <row> <entry role="catalog_table_entry"><para role="column_definition"> - <structfield>lines_processed</structfield> <type>bigint</type> + <structfield>tuples_excluded</structfield> <type>bigint</type> </para> <para> - Number of lines already processed by <command>COPY</command> command. + Number of tuples not processed because they were excluded by the + <command>WHERE</command> clause of the <command>COPY</command> command. </para></entry> </row> </tbody> |