RefLib

Reference library for AI

Back

postgresql_16:9.5.7.2 Changes

PostgreSQL 16 > Appendixes > Release Notes > Release 16.9 > Changes

While unlikely, a SIGSEGV crash could occur if an incomplete multibyte character appeared at the end of memory. This was possible both in the server and in libpq-using applications. (CVE-2025-4207)

Creating or attaching partitions failed to make the required catalog entries for a foreign-key constraint, if the table referenced by the constraint was the same partitioned table. This resulted in failure to enforce the constraint fully.

To fix this, you should drop and recreate any self-referential foreign keys on partitioned tables, if partitions have been created or attached since the constraint was created. Bear in mind that violating rows might already be present, in which case recreating the constraint will fail, and you'll need to fix up those rows before trying again.

The code failed to account for decompression results not being identical to the input objects, which would result in failure to add some of the data to the merged summary, leading to missed rows in index searches.

This mistake was present back to v14 where BRIN bloom indexes were introduced, but this code path was only rarely reached then. It's substantially more likely to be hit in v17 because parallel index builds now use the code.

Some cases failed with “unknown action in MERGE WHEN clause” errors.

Constraint failure was reported even if the generation expression produced a perfectly okay result.

The parser failed to detect disallowed recursion cases, nor did it account for such references when sorting CTEs into a usable order.

The protocol for communicating with parallel workers doesn't support identifying the concrete record type that a worker is returning.

This patch restores the behavior that existed before PostgreSQL 9.5: the result is of type int2vector[] or oidvector[].

If a domain type has a default, adding a column of that type (without any explicit DEFAULT clause) failed to install the domain's default value in existing rows, instead leaving the new column null.

Previously, views or rules using XMLSERIALIZE(... INDENT) were dumped without the INDENT clause, causing incorrect results after restore.

If there is ORDER BY or DISTINCT, we consider pre-sorting the aggregate input values rather than doing the sort within the Agg plan node. But this is problematic if the aggregate inputs include expressions that could fail (for example, a division where some of the input divisors could be zero) and there is a FILTER clause that's meant to prevent such failures. Pre-sorting would push the expression evaluations to before the FILTER test, allowing the failures to happen anyway. Avoid this by not pre-sorting if there's a FILTER and the input expressions are anything more complex than a simple Var or Const.

This resulted in unnecessarily-inefficient execution of any additional subexpressions that could have been processed with a hash table (that is, IN, NOT IN, or = ANY clauses with all-constant right-hand sides).

It turns out that this optimization can result in returning dead tuples when a concurrent vacuum marks a page all-visible.

An indexable clause with many keys (for example, jsonbcol ?| array[...] with tens of thousands of array elements) took O(N2) time to start up, and was uncancelable for that interval too.

Previously, nothing would happen until one of the subplans becomes ready.

Previously, the pg_stat_io view failed to accumulate I/O performed by a WAL sender until that process exited. Now such I/O will be reported after at most one second's delay.

For a short period after system startup, backends might fail to wait for synchronous commit even though synchronous_standby_names is enabled.

This prevents trouble when the invalid slot points to WAL that's already been removed.

This prevents a scenario where the slot could remain valid after promotion even if wal_level is too low.

This mistake could allow deleted catalog entries to be vacuumed away even though they were still potentially needed by the WAL-reading process.

The catalog changes caused by the DDL command were not reflected into WAL-decoding processes, allowing them to decode subsequent changes using stale catalog data, probably resulting in data corruption.

This mistake could allow duplicate data to be applied.

Subscription creation gives a warning if a subscribed-to table is also being followed through other publications, since that could cause duplicate data to be received. This change improves that logic to also detect cases where a partition parent or child table is the one being followed through another publication.

If the requested recovery timeline is not reachable, the reported checkpoint and timeline should be the values read from the backup_label, if there is one. This message previously reported values from the control file, which is correct when recovering from the control file without a backup_label, but not when there is a backup_label.

The server rejects such DROP commands. That has no real consequences, since the partitions will go away anyway in the subsequent DROPs of either their parent tables or their partitioned index. However, the error reported for the attempted drop causes problems when restoring in --single-transaction mode.

Instead, print a warning and skip the entry. This copes better with catalog corruption that has been seen to occur in back branches as a result of race conditions between GRANT and DROP ROLE.

These oversights could result in crashes in certain Windows build configurations, such as a debug build of libpq used by a non-debug build of the calling application.

This change back-patches a v17-era fix. It prevents possible hangs in CREATE DATABASE and DROP DATABASE due to failure to detect deadlocks.

Applying pg_freespacemap() to a relation lacking storage (such as a view) caused an assertion failure, although there was no ill effect in non-assert builds. Add an error check to reject that case.

This macOS update broke our configuration probe for strchrnul().

There is a new time zone America/Coyhaique for Chile's Aysén Region, to account for it changing to UTC-03 year-round and thus diverging from America/Santiago.

Back