pgsql: pg_archivecleanup: Add --clean-backup-history

2023-07-18 Thread Michael Paquier
pg_archivecleanup: Add --clean-backup-history By default, pg_archivecleanup does not remove backup history files. These are just few bytes useful for debugging purposes, still keeping them around can bloat an archive path history files mixed with the WAL segments if the path has a long history. T

pgsql: pg_archivecleanup: Refactor loop doing old segment removals

2023-07-18 Thread Michael Paquier
pg_archivecleanup: Refactor loop doing old segment removals This commit refactors a bit the main loop of pg_archivecleanup that handles the removal of old segments, reducing by one its level of indentation. This will help an incoming patch that adds a new option related to the segment filtering l

pgsql: Doc: Update the logical replication restriction w.r.t Replica Id

2023-07-18 Thread Amit Kapila
Doc: Update the logical replication restriction w.r.t Replica Identity Full. Author: Kuroda Hayato Reviewed-by: Peter Smith, Onder Kalaci, Sergei Kornilov, Amit Kapila Discussion: https://postgr.es/m/tyapr01mb58662174ed62648e0d611194f5...@tyapr01mb5866.jpnprd01.prod.outlook.com Branch -- mas

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show

pgsql: Doc: fix out-of-date example of SPI usage.

2023-07-18 Thread Tom Lane
Doc: fix out-of-date example of SPI usage. The "count" argument of SPI_exec() only limits execution when the query is actually returning rows. This was not the case before PG 9.0, so this example was correct when written; but we missed updating it in commit 2ddc600f8. Extend the example to show