Major enhancements in <productname>PostgreSQL</productname> 13 include:
</para>
<!-- Items in this list summarize one or more items below -->
<itemizedlist>
<listitem>
<para></para>
</listitem>
</itemizedlist>
<para>
The above items are explained in more detail in the sections below.
</para>
</sect2>
<sect2>
<title>Migration to Version 13</title>
<para>
A dump/restore using <xref linkend="app-pg-dumpall"/> or use of <xref
linkend="pgupgrade"/> or logical replication is required for those
wishing to migrate data from any previous release. See <xref
linkend="upgrading"/> for general information on migrating to new major
releases.
</para>
<para>
Version 13 contains a number of changes that may affect compatibility
with previous releases. Observe the following incompatibilities:
</para>
<itemizedlist>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-09-07 [ca70bdaef] Fix issues around strictness of SIMILAR TO.
-->
<para>
Change SIMILAR TO ... ESCAPE NULL to return NULL (Tom Lane)
</para>
<para>
This new behavior matches the SQL specification. Previously this caused the escape to be set to the default backslash character. The previous behavior has been retained in old views by keeping the
original function unchanged. This also applies to substring(text FROM pattern ESCAPE text).
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-01-31 [870ad6a59] Fix not-quite-right string comparison in parse_jsonb_ind
-->
<para>
Have parse_jsonb_index_flags() properly check "string" parameter (Dominik Czarnota)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-28 [9950c8aad] Fix lquery's behavior for consecutive '*' items.
-->
<para>
In ltree, when using adjacent asterisks with braces, e.g. "*{2}.*{3}", properly interpret that as "*{5}" (Nikita Glukhov)
</para>
</listitem>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2020-03-16 [b09ff5366] Simplify the effective_io_concurrency setting.
-->
<para>
Change the way non-default effective_io_concurrency values affect concurrency (Thomas Munro)
</para>
<para>
Previously, this value was adjusted before effecting the number of concurrent requests. This value is now used directly. Conversion of old values to new ones can be done using:
</para>
<para>
SELECT round(sum(OLD / n::float)) FROM generate_series(1, OLD) s(n);
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2019-11-12 [5c46e7d82] pg_stat_{ssl,gssapi}: Show only processes with connectio
-->
<para>
Prevent display of auxiliary processes in pg_stat_ssl and pg_stat_gssapi system views (Euler Taveira)
</para>
<para>
Queries that join these views to pg_stat_activity and wish to see auxiliary processes will need to use left joins.
</para>
</listitem>
<listitem>
<!--
Author: Peter Geoghegan <pg@bowt.ie>
2020-03-07 [691e8b2e1] pageinspect: Fix types used for bt_metap() columns.
-->
<para>
Fix pageinspect's bt_metap() to return more appropriate data types that are less likely to overflow (Peter Geoghegan)
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2020-03-19 [1d253bae5] Rename the recovery-related wait events.
-->
<para>
Rename some recovery-related wait events (Fujii Masao)
</para>
<para>
Rename RecoveryWalAll to RecoveryWalStream and RecoveryWalStream to RecoveryRetrieveRetryInterval.
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2019-11-06 [979766c0a] Correct the command tags for ALTER ... RENAME COLUMN.
-->
<para>
Fix ALTER FOREIGN TABLE ... RENAME COLUMN to return a more appropriate command tag (Fujii Masao)
</para>
<para>
Previously it returned "ALTER TABLE", but now returns "ALTER FOREIGN TABLE".
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2019-11-06 [979766c0a] Correct the command tags for ALTER ... RENAME COLUMN.
-->
<para>
Fix ALTER MATERIALIZED VIEW ... RENAME COLUMN to return a more appropriate command tag (Fujii Masao)
</para>
<para>
Previously it returned "ALTER TABLE", but now returns "ALTER MATERIALIZED VIEW".
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-05 [84eca14bc] Remove ancient hacks to ignore certain opclass names in
-->
<para>
Remove support for defining operator classes using pre-Postgres 8.0 syntax (Daniel Gustafsson)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-05 [e58a59975] Remove ancient support for upgrading pre-7.3 foreign key
-->
<para>
Remove support for defining foreign key constraints using pre-Postgres 7.3 syntax (Daniel Gustafsson)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-05 [bb03010b9] Remove the "opaque" pseudo-type and associated compatibi
-->
<para>
Remove support for "opaque" pseudo-types used by pre-Postgres 7.3 servers (Daniel Gustafsson)
</para>
</listitem>
</itemizedlist>
</sect2>
<sect2>
<title>Changes</title>
<para>
Below you will find a detailed account of the changes between
<productname>PostgreSQL</productname> 13 and the previous
2019-08-07 [4e85642d9] Apply constraint exclusion more generally in partitionin
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2019-08-13 [815ef2f56] Don't constraint-exclude partitioned tables as much
-->
<para>
Improve cases where pruning of partitions can happen (Amit Langote, Yuzuko Hosoya, Álvaro Herrera)
</para>
</listitem>
<listitem>
<!--
Author: Etsuro Fujita <efujita@postgresql.org>
2020-04-08 [c8434d64c] Allow partitionwise joins in more cases.
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-04-07 [981643dcd] Allow partitionwise join to handle nested FULL JOIN USIN
-->
<para>
Allow partitionwise joins to happen in more cases (Ashutosh Bapat, Etsuro Fujita, Amit Langote)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-03-18 [487e9861d] Enable BEFORE row-level triggers for partitioned tables
-->
<para>
Allow BEFORE row-level triggers on partitioned tables (Alvaro Herrera)
</para>
<para>
These triggers cannot change the destination partition.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-04-06 [f1ac27bfd] Add logical replication support to replicate into partit
-->
<para>
Allow logical replication to replicate partitioned tables (Amit Langote)
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-03-10 [17b9e7f9f] Support adding partitioned tables to publication
-->
<para>
Allow partitioned tables to be added to replicated publications (Amit Langote)
</para>
<para>
Partition additions/removals are replicated as well. Previously, partitions had to be replicated individually. HOW IS THIS DIFFERENT FROM THE ITEM ABOVE?
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-04-08 [83fd4532a] Allow publishing partition changes via ancestors
-->
<para>
Allow CREATE PUBLICATION to control whether partitioned tables are published as themselves or their ancestors (Amit Langote)
</para>
<para>
The option is publish_via_partition_root.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-12-25 [bb4114a4e] Allow whole-row Vars to be used in partitioning expressi
-->
<para>
Allow ROW values to be used as partitioning expressions (Amit Langote)
</para>
</listitem>
</itemizedlist>
</sect4>
<sect4>
<title>Indexes</title>
<itemizedlist>
<listitem>
<!--
Author: Peter Geoghegan <pg@bowt.ie>
2020-02-26 [0d861bbb7] Add deduplication to nbtree.
-->
<para>
More efficiently store duplicates in btree indexes (Anastasia Lubennikova, Peter Geoghegan)
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2019-07-14 [c085e1c1c] Add support for <-> (box, point) operator to GiST box_op
Author: Alexander Korotkov <akorotkov@postgresql.org>
2019-07-14 [075f0a880] Add support for <-> (box, point) operator to SP-GiST box
-->
<para>
Allow GiST and SP-GiST indexes for box/point distance lookups (Nikita Glukhov)
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2020-03-30 [911e70207] Implement operator class parameters
-->
<para>
Allow index operator classes to take parameters (Nikita Glukhov)
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2020-03-30 [911e70207] Implement operator class parameters
-->
<para>
Allow CREATE INDEX to specify the GiST signature length and maximum number of integer ranges (Nikita Glukhov)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-12-06 [fbbf68094] Disallow non-default collation in ADD PRIMARY KEY/UNIQUE
-->
<para>
Prevent indexes that use non-default collations from being added as a table's unique or primary key constraint (Tom Lane)
</para>
<para>
The index and column collations must now match so the index's uniqueness matches the column's uniqueness.
</para>
</listitem>
</itemizedlist>
</sect4>
<sect4>
<title>Optimizer</title>
<itemizedlist>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-04-01 [a80818605] Improve selectivity estimation for assorted match-style
-->
<para>
Improve the optimizer's selectivity estimation for containment/match operators (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2019-09-11 [d06215d03] Allow setting statistics target for extended statistics
-->
<para>
Allow setting statistics target for extended statistics (Tomas Vondra)
</para>
<para>
This is controlled with the new command option ALTER STATISTICS ... SET STATISTICS. Previously this was computed based on more general statistics target settings.
</para>
</listitem>
<listitem>
<!--
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-01-13 [aaa676187] Apply all available functional dependencies
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-01-13 [eae056c19] Apply multiple multivariate MCV lists when possible
-->
<para>
Allow use of multiple extended statistics objects in a single query (Tomas Vondra)
</para>
</listitem>
<listitem>
<!--
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-03-14 [8f321bd16] Use functional dependencies to estimate ScalarArrayOpExp
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-03-14 [e83daa7e3] Use multi-variate MCV lists to estimate ScalarArrayOpExp
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-03-18 [ccaa3569f] Recognize some OR clauses as compatible with functional
-->
<para>
Allow use of extended statistics objects for OR clauses and IN/ANY constant lists (Pierre Ducroquet, Tomas Vondra)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-08-01 [7266d0997] Allow functions-in-FROM to be pulled up if they reduce t
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-09-24 [a9ae99d01] Prevent bogus pullup of constant-valued functions return
-->
<para>
Allow functions in FROM clauses to be moved to their reference sites if they evaluate to constants (Alexander Kuzmenkov, Aleksandr Parfenov)
</para>
</listitem>
</itemizedlist>
</sect4>
<sect4>
<title>General Performance</title>
<itemizedlist>
<listitem>
<!--
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2020-04-06 [d2d8a229b] Implement Incremental Sort
-->
<para>
Allow incremental sorting (James Coleman, Alexander Korotkov)
</para>
<para>
If a result is already sorted by several keys, this allows for batch sorting of additional trailing keys because the previous keys are already equal. This is controlled by enable_incrementalsort.
</para>
</listitem>
<listitem>
<!--
Author: Peter Geoghegan <pg@bowt.ie>
2019-08-01 [71dcd7438] Add sort support routine for the inet data type.
-->
<para>
Improve the performance of sorting inet values (Brandur Leach)
Improve retrieving of only the leading bytes of TOAST values (Binguo Bao)
</para>
<para>
Previously, TOAST values were fully fetched and only the requested leading bytes were decompressed and returned. Now, only the requested bytes are fetched.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-09-10 [bca6e6435] Reduce overhead of scanning the backend[] array in LISTE
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-09-22 [51004c717] Make some efficiency improvements in LISTEN/NOTIFY.
-->
<para>
Improve performance of LISTEN/NOTIFY (Martijn van Oosterhout)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-08-15 [bb5ae8f6c] Use a hash table to de-duplicate NOTIFY events faster.
-->
<para>
Improve the efficiency of removing duplicate NOTIFY events (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Andrew Gierth <rhodiumtoad@postgresql.org>
2020-02-01 [1fd687a03] Optimizations for integer to decimal output.
-->
<para>
Use lookup tables to speed up integer to text conversion (David Fetter)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-07-10 [b5810de3f] Reduce memory consumption for multi-statement query stri
-->
<para>
Reduce memory usage for query strings that contain multiple SQL statements (Amit Langote)
</para>
</listitem>
</itemizedlist>
</sect4>
<sect4>
<title>Monitoring</title>
<itemizedlist>
<listitem>
<!--
Author: Amit Kapila <akapila@postgresql.org>
2020-04-05 [6b466bf5f] Allow pg_stat_statements to track WAL usage statistics.
Author: Amit Kapila <akapila@postgresql.org>
2020-04-06 [33e05f89c] Add the option to report WAL usage in EXPLAIN and auto_e
Author: Amit Kapila <akapila@postgresql.org>
2020-04-06 [b7ce6de93] Allow autovacuum to log WAL usage statistics.
-->
<para>
Allow EXPLAIN, auto_explain, autovacuum, and pg_stat_statements to track WAL usage statistics (Kirill Bychik, Julien Rouhaud)
</para>
</listitem>
<listitem>
<!--
Author: Tomas Vondra <tomas.vondra@postgresql.org>
2019-11-06 [6e3e6cc0e] Allow sampling of statements depending on duration
-->
<para>
Allow a sample of statements to be logged (Adrien Nayrat)
</para>
<para>
A log_statement_sample_rate ratio of statements taking over log_min_duration_sample duration will be logged.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-03-15 [70a7b4776] Add backend type to csvlog and optionally log_line_prefi
-->
<para>
Add the backend type to csvlog and optionally log_line_prefix log output (Peter Eisentraut)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2019-12-11 [ba79cb5dc] Emit parameter values during query bind/execute errors
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-04-02 [0b34e7d30] Improve user control over truncation of logged bind-para
-->
<para>
Improve control of prepared statement parameter logging (Alexey Bashtanov, Álvaro Herrera)
</para>
<para>
The GUC setting log_parameter_max_length controls the maximum length of parameter values output during statement logging, and log_parameter_max_length_on_error allows parameters to be output on
error.
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-02-05 [15d13e829] Make vacuum buffer counters 64 bits wide
-->
<para>
Make vacuum buffer counters 64-bits wide to avoid overflow (Alvaro Herrera)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2019-11-08 [71a8a4f6e] Add backtrace support for error reporting
-->
<para>
Allow function call backtraces of errors to be logged (Peter Eisentraut, Álvaro Herrera)
</para>
<para>
Server variable backtrace_functions specifies which C functions should generate backtraces on error.
</para>
</listitem>
<listitem>
<!--
Author: Michael Paquier <michael@paquier.xyz>
2019-07-05 [313f87a17] Add min() and max() aggregates for pg_lsn
-->
<para>
Add min() and max() aggregates for pg_lsn (Fabrízio de Royes Mello)
</para>
<para>
This is useful for monitoring queries.
</para>
</listitem>
</itemizedlist>
</sect4>
<sect4>
<title>System Views</title>
<itemizedlist>
<listitem>
<!--
Author: Michael Paquier <michael@paquier.xyz>
2020-02-06 [b025f32e0] Add leader_pid to pg_stat_activity
-->
<para>
Add leader_pid to pg_stat_activity to report parallel worker ownership (Julien Rouhaud)
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2020-03-03 [e65497df8] Report progress of streaming base backup.
-->
<para>
Add system view pg_stat_progress_basebackup to report the progress of streaming base backups (Fujii Masao)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-01-15 [a166d408e] Report progress of ANALYZE commands
-->
<para>
Add system view pg_stat_progress_analyze to report analyze progress (Álvaro Herrera, Tatsuro Yamada)
</para>
</listitem>
<listitem>
<!--
Author: Amit Kapila <akapila@postgresql.org>
2019-11-21 [9290ad198] Track statistics for spilling of changes from ReorderBuf
-->
<para>
Add columns to the pg_stat_replication system view to report how much logical decoding information has been spilled to disk (Tomas Vondra)
This combines existing options LC_COLLATE and LC_CTYPE into a single option.
</para>
</listitem>
<listitem>
<!--
Author: Amit Kapila <akapila@postgresql.org>
2019-11-13 [1379fd537] Introduce the 'force' option for the Drop Database comma
-->
<para>
Allow DROP DATABASE to disconnect users so drop succeeds (Pavel Stehule, Amit Kapila)
</para>
<para>
This is enabled by WITH FORCE.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-03-09 [71d60e2aa] Add tg_updatedcols to TriggerData
-->
<para>
Add C structure member tg_updatedcols to record updated columns to C triggers (Peter Eisentraut)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-03-20 [4e6209134] pg_dump: Add FOREIGN to ALTER statements, if appropriate
-->
<para>
Add FOREIGN to ALTER statements, if appropriate (Luis Carril)
</para>
<para>
WHAT IS THIS ABOUT?
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3>
<title>Data Types</title>
<itemizedlist>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2020-04-07 [aeec457de] Add SQL type xid8 to expose FullTransactionId to users.
-->
<para>
Add SQL data type xid8 to expose FullTransactionId (Thomas Munro)
</para>
<para>
The xid data type is only four bytes so does not show the transaction epoch.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-03-18 [a2b1faa0f] Implement type regcollation
-->
<para>
Add data type regcollation and helper functions for system collations (Julien Rouhaud)
</para>
</listitem>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2019-10-16 [d5ac14f9c] Use libc version as a collation version on glibc systems
-->
<para>
Use the glibc version as the collation version (Thomas Munro)
</para>
<para>
If the glibc version changes, a warning will be issued when a mismatching collation is used.
</para>
</listitem>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2020-03-25 [352f6f2df] Add collation versions for Windows.
-->
<para>
Add support for collation versions on Windows (Juan José Santamaría Flecha)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-10-28 [8b7a0f1d1] Allow extracting fields from a ROW() expression in more
-->
<para>
Allow ROW values to have their members extracted with suffix notation (Tom Lane)
</para>
<para>
For example, (ROW(4, 5.0)).f1 returns 4.
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3>
<title>Functions</title>
<itemizedlist>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2020-01-17 [a83586b55] Add a non-strict version of jsonb_set
-->
<para>
Add alternate version of jsonb_set with special NULL handling (Andrew Dunstan)
</para>
<para>
The new function, jsonb_set_lax(), allows null new values to either set the specified key to JSON null, delete the key, raise exception, or ignore operation.
IS 'return_target' CLEAR?
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
This allows json values to be converted to timestamps, which can then be processed in jsonpath expressions. This also adds jsonpath functions that support time zone-aware output.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-04-02 [2991ac5fc] Add SQL functions for Unicode normalization
-->
<para>
Add SQL functions NORMALIZE() to normalize Unicode strings, and IS NORMALIZED to check for normalization (Peter Eisentraut)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-06 [a6525588b] Allow Unicode escapes in any server encoding, not only U
-->
<para>
Allow UTF-8 escapes, e.g., E'\u####', in clients that don't use UTF-8 encoding (Tom Lane)
</para>
<para>
The UTF-8 characters must be available in the server encoding.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-03 [d67755049] Allow to_date/to_timestamp to recognize non-English mont
-->
<para>
Allow to_date() and to_timestamp() to recognize non-English month/day names (Juan José Santamaría Flecha)
</para>
<para>
The names recognized are the same as those output by to_char() with the same format codes.
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2019-09-16 [d589f9446] Support for FF1-FF6 datetime format patterns
-->
<para>
Add format specifications FF1-FF6 to control display of 1-6 subsecond digits (Alexander Korotkov, Nikita Glukhov, Teodor Sigaev, Oleg Bartunov)
</para>
<para>
These patterns can be used by to_char(), to_timestamp(), and jsonpath's .datetime().
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2019-09-16 [b64b857f5] Support for SSSSS datetime format pattern
-->
<para>
Add SSSSS time format specification as an SQL standard alias for SSSS (Nikita Glukhov, Alexander Korotkov)
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2019-07-14 [5925e5549] Add gen_random_uuid function
-->
<para>
Add function gen_random_uuid to generate version 4 UUIDs (Fabien COELHO)
</para>
<para>
Previously UUID generation functions were only available external modules uuid-ossp or pgcrypto were installed.
</para>
</listitem>
<listitem>
<!--
Author: Dean Rasheed <dean.a.rasheed@gmail.com>
2020-01-25 [13661ddd7] Add functions gcd() and lcm() for integer and numeric ty
-->
<para>
Add greatest-common-denominator (gcd) and least-common-multiple (lcm) functions (Vik Fearing)
</para>
</listitem>
<listitem>
<!--
Author: Dean Rasheed <dean.a.rasheed@gmail.com>
2020-03-01 [43a899f41] Fix corner-case loss of precision in numeric ln().
Author: Dean Rasheed <dean.a.rasheed@gmail.com>
2020-03-28 [4083f445c] Improve the performance and accuracy of numeric sqrt() a
-->
<para>
Improve the performance and accuracy of square root and natural log (ln) output (Dean Rasheed)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-01-06 [20d6225d1] Add functions min_scale(numeric) and trim_scale(numeric)
-->
<para>
Add function min_scale() that returns the number of digits to the right the decimal point that is required to represent the numeric value with full precision (Pavel Stehule)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-01-06 [20d6225d1] Add functions min_scale(numeric) and trim_scale(numeric)
-->
<para>
Add function trim_scale() to reduce the scale of a number by removing trailing zeros (Pavel Stehule)
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2019-07-14 [6254c55f8] Add missing commutators for distance operators
-->
<para>
Add commutators of distance operators (Nikita Glukhov)
</para>
<para>
For example, previously only point <-> line was supported, now line <-> point works too.
</para>
</listitem>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2020-04-07 [4c04be9b0] Introduce xid8-based functions to replace txid_XXX.
-->
<para>
Update all transaction id functions to support xid8 (Thomas Munro)
</para>
<para>
They use the same names as the xid data type versions.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-04-07 [26a944cf2] Adjust bytea get_bit/set_bit to use int8 not int4 for bi
-->
<para>
Allow get_bit() and set_bit() to set bits beyond 256MB of bytea data (Movead Li)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-08-01 [4886da832] Mark advisory-lock functions as parallel restricted, not
-->
<para>
Allow advisory-lock functions to be used in some parallel operations (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Alvaro Herrera <alvherre@alvh.no-ip.org>
2020-04-20 [5fc703946] Add ALTER .. NO DEPENDS ON
-->
<para>
Add the ability to remove a function's dependency on an extension (Alvaro Herrera)
Allow libpq clients to require channel binding (Jeff Davis)
</para>
<para>
Using the libpq connection parameter 'channel_binding' forces the other end of the TLS connection to prove it knows the user's password. This prevents man-in-the-middle attacks.
</para>
</listitem>
<listitem>
<!--
Author: Michael Paquier <michael@paquier.xyz>
2020-01-28 [ff8ca5fad] Add connection parameters to control SSL protocol min/ma
Author: Michael Paquier <michael@paquier.xyz>
2020-04-30 [401aad670] Rename connection parameters to control min/max SSL prot
-->
<para>
Add libpq connection parameters to control the min/max TLS version (Daniel Gustafsson)
</para>
<para>
The settings are min_protocol_version and max_protocol_version.
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2020-03-05 [2eb3bc588] Fix issues around .pgpass file.
-->
<para>
Tighten line length and comment detection in .pgpass files (Fujii Masao)
</para>
</listitem>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2019-11-30 [4dc635521] libq support for sslpassword connection param, DER form
-->
<para>
Allow specification of passwords to unlock client certificates (Craig Ringer, Andrew Dunstan)
</para>
<para>
This is specified by the sslpassword connection option.
</para>
</listitem>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2019-11-30 [4dc635521] libq support for sslpassword connection param, DER form
-->
<para>
Allow DER-encoded client certificates (Craig Ringer, Andrew Dunstan)
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3>
<title>Client Applications</title>
<sect4>
<title><xref linkend="app-psql"/></title>
<itemizedlist>
<listitem>
<!--
Author: Michael Paquier <michael@paquier.xyz>
2020-02-12 [dcdbb5a5d] Add %x to default PROMPT1 and PROMPT2 in psql
-->
<para>
Add the transaction status (%x) to the default psql prompts (Vik Fearing)
</para>
</listitem>
<listitem>
<!--
Author: Thomas Munro <tmunro@postgresql.org>
2019-11-19 [7f338369c] Allow invisible PROMPT2 in psql.
-->
<para>
Allow the secondary psql prompt to be same number of spaces as the primary prompt (Thomas Munro)
</para>
<para>
This is accomplished by setting PROMPT2 to %w.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-04-07 [b63c293bc] Allow psql's \g and \gx commands to transiently change \
-->
<para>
Allow \g and \gx to change any pset output options for a single command (Tom Lane)
</para>
<para>
This makes \gx equivalent to \g (expanded=on).
</para>
</listitem>
<listitem>
<!--
Author: Alexander Korotkov <akorotkov@postgresql.org>
2020-03-08 [b0b5e20cd] Show opclass and opfamily related information in psql
-->
<para>
Add psql commands to report operator classes and operator families (Sergey Cherkashin, Nikita Glukhov, Alexander Korotkov)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-07-03 [9a2ea6183] Show table persistence in psql's \dt+ and related comman
-->
<para>
Show table persistence in psql's \dt+ and related commands (David Fetter)
</para>
<para>
In verbose mode, the table/index/view shows if the object is permanent, temporary, or unlogged.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-07-23 [eb5472da9] Improve psql's \d output for TOAST tables.
-->
<para>
Improve output of psql \d for TOAST tables (Justin Pryzby)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-11-22 [d1c866e57] Make psql redisplay the query buffer after \e.
-->
<para>
Adjust display of psql's \e query (Tom Lane)
</para>
<para>
When exiting the editor, if the query doesn't end with a semicolon or \g, the query buffer contents will now be displayed.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-07-05 [02e95a504] Add \warn command to psql.
-->
<para>
Add \warn command to psql (David Fetter)
</para>
<para>
This is like \echo except that the text is sent to stderr instead of stdout.
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-02-28 [1933ae629] Add PostgreSQL home page to - -help output
-->
<para>
Add the PostgreSQL home page to command-line --help output (Peter Eisentraut)
2020-03-19 [fab13dc50] Make pg_basebackup ask the server to estimate the total
-->
<para>
Have pg_basebackup estimate the total backup size by default (Fujii Masao)
</para>
<para>
This computation allows pg_stat_progress_basebackup to show progress, and can be disabled by using the --no-estimate-size option. Previously, this computation happened only if --progress was used.
This was needed for previously supported version-zero functions.
</para>
</listitem>
<listitem>
<!--
Author: Fujii Masao <fujii@postgresql.org>
2020-03-30 [6aba63ef3] Allow the planner-related functions and hook to accept t
-->
<para>
Add the query string to planner hook functions (Pascal Legrand, Julien Rouhaud)
</para>
</listitem>
<listitem>
<!--
Author: Joe Conway <mail@joeconway.com>
2019-11-23 [f7a2002e8] Add object TRUNCATE hook
-->
<para>
Add TRUNCATE command hook (Yuli Khodorkovskiy)
</para>
</listitem>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2020-03-25 [896fcdb23] Provide a TLS init hook
-->
<para>
Add TLS init hook (Andrew Dunstan)
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2020-01-31 [a9cff89f7] Allow building without default socket directory
-->
<para>
Allow building with no predefined Unix-domain socket directory (Peter Eisentraut)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-09-05 [7de19fbc0] Use data directory inode number, not port, to select Sys
-->
<para>
Reduce the probability of SysV resource key collision on Unix platforms (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Peter Eisentraut <peter@eisentraut.org>
2019-09-05 [74a308cf5] Use explicit_bzero
-->
<para>
Use operating system functions to cleanly erase memory that contains sensitive information (Peter Eisentraut)
</para>
<para>
For example, this is used for clearing passwords stored in memory.
</para>
</listitem>
<listitem>
<!--
Author: Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-08-19 [55ea10918] Add "headerscheck" script to test header-file compilabil
-->
<para>
Add "headerscheck" script to test C header-file compatibility (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2019-07-15 [1cff1b95a] Represent Lists as expansible arrays, not chains of cons
-->
<para>
Implement internal lists as arrays, rather than a chain of structures (Tom Lane)
</para>
<para>
This improves performance for queries that access many object. The internal List API has also been improved.
</para>
</listitem>
<listitem>
<!--
Author: Michael Paquier <michael@paquier.xyz>
2019-07-13 [39aadc984] Fix some inconsistencies in MSVC scripts
-->
<para>
Update Windows build scripts to use the modern --with-uuid flag for UUID libraries (Kyotaro Horiguchi)
</para>
</listitem>
</itemizedlist>
</sect3>
<sect3>
<title>Additional Modules</title>
<itemizedlist>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-01-29 [50fc694e4] Invent "trusted" extensions, and remove the pg_pltemplat
-->
<para>
Allow extensions to be specified as trusted (Tom Lane)
</para>
<para>
Such extensions can be installed in a database by users with creation rights, even if they are not super users. This change also removes the pg_pltemplate system catalog.
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-02-19 [70a773200] Remove support for upgrading extensions from "unpackaged
-->
<para>
Remove support for upgrading "unpackaged" extensions (Tom Lane)
</para>
</listitem>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2019-12-20 [6136e94dc] Superuser can permit passwordless connections on postgre
-->
<para>
Allow non-super users to connect to postgres_fdw foreign servers without using a password (Craig Ringer)
</para>
<para>
Specifically, allow ALTER USER MAPPING to set password_required to false. Care must still be taken to avoid non-super users from using super user credentials to connect to the foreign server.
</para>
</listitem>
<listitem>
<!--
Author: Andrew Dunstan <andrew@dunslane.net>
2020-01-09 [f5fd995a1] Allow 'sslkey' and 'sslcert' in postgres_fdw user mappin
-->
<para>
Allow postgres_fdw to use certificate authentication (Craig Ringer)
</para>
<para>
Different users can use different certificates.
</para>
</listitem>
<listitem>
<!--
Author: Joe Conway <mail@joeconway.com>
2019-11-23 [4f66c93f6] Update sepgsql to add mandatory access control for TRUNC
-->
<para>
Allow sepgsql to control access to the TRUNCATE command (Yuli Khodorkovskiy)
</para>
</listitem>
<listitem>
<!--
Author: Tom Lane <tgl@sss.pgh.pa.us>
2020-03-06 [36058a3c5] Create contrib/bool_plperl to provide a bool transform f