<feed xmlns='http://www.w3.org/2005/Atom'>
<title>postgresql.git/src/test/regress/sql/strings.sql, branch master</title>
<subtitle>This is the main PostgreSQL git repository.</subtitle>
<id>http://git.postgresql.org/cgit/postgresql.git/atom?h=master</id>
<link rel='self' href='http://git.postgresql.org/cgit/postgresql.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/'/>
<updated>2026-09-15T02:30:45Z</updated>
<entry>
<title>Add battery of tests related TOAST tables with oid8</title>
<updated>2026-09-15T02:30:45Z</updated>
<author>
<name>Michael Paquier</name>
</author>
<published>2026-09-15T02:30:45Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=c68cba09dd7fb2cca1fdddfcf8e0fe206e97a8a4'/>
<id>urn:sha1:c68cba09dd7fb2cca1fdddfcf8e0fe206e97a8a4</id>
<content type='text'>
The tests added by this commit cover a large ground in terms of the
introduction of oid8 in TOAST tables, with the following areas covered,
with all the gaps found during the development of the feature:
- Tables with oid8 TOAST tables in general, under strings.sql.
- ALTER TABLE with attribute manipulations in transactions and different
toast_table_value settings.
- Relation rewrites, not affecting the TOAST relation after initial
creation with VACUUM FULL, CLUSTER, REPACK.
- pg_column_compression().
- test_decoding, for external and extended TOAST data.
- amcheck, external and extended storage with heap checked.
- UPDATE with out-of-line datums that belongs to another TOAST table.
This offers coverage for toast_tuple_init(), where external vartags
could be mixed once multiple on-disk external TOAST pointers can
co-exist.  This pattern can be triggered with asan/ubsan, with an
out-of-bound memcpy when unpatched.

These tests are added before the new vartag_external, mostly as a matter
of avoiding dead code in the tree.

Author: Michael Paquier &lt;michael@paquier.xyz&gt;
Reviewed-by: Greg Burd &lt;greg@burd.me&gt;
Reviewed-by: Bharath Rupireddy &lt;bharath.rupireddyforpostgres@gmail.com&gt;
Reviewed-by: Yugo Nagata &lt;nagata@sraoss.co.jp&gt;
Discussion: https://postgr.es/m/af19kUjwjhaoUTLn@paquier.xy
</content>
</entry>
<entry>
<title>Fix truncation rules for base64 encoding</title>
<updated>2026-07-17T13:40:16Z</updated>
<author>
<name>Daniel Gustafsson</name>
</author>
<published>2026-07-17T13:40:16Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=1f414035135cca34b606d4c0d3db0eb57045e00b'/>
<id>urn:sha1:1f414035135cca34b606d4c0d3db0eb57045e00b</id>
<content type='text'>
Commit e1d917182 added support for base64url encoding, a base64 variant
intended to be safe for usage in URLs and filenames.  The padding rules
for base64url and base64 differ in that base64url require no extra '='
padding, but the commit unintentionally relaxed this requirement for
base64 as well.  Fix by making sure that the truncation logic check
for the encoding and add a test to make sure.

Backpatch down to v19 where support for base64url was introduced.

Author: Daniel Gustafsson &lt;daniel@yesql.se&gt;
Reviewed-by: David E. Wheeler &lt;david@justatheory.com&gt;
Discussion: https://postgr.es/m/3258FC72-F5E1-40B9-B5D7-64478CAF7728@yesql.se
Backpatch-through: 19
</content>
</entry>
<entry>
<title>Add base32hex support to encode() and decode() functions.</title>
<updated>2026-03-25T18:35:19Z</updated>
<author>
<name>Masahiko Sawada</name>
</author>
<published>2026-03-25T18:35:19Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=497c1170cb108cd84fe13db19c049177376fec5f'/>
<id>urn:sha1:497c1170cb108cd84fe13db19c049177376fec5f</id>
<content type='text'>
This adds support for base32hex encoding and decoding, as defined in
RFC 4648 Section 7. Unlike standard base32, base32hex uses the
extended hex alphabet (0-9, A-V) which preserves the lexicographical
order of the encoded data.

This is particularly useful for representing UUIDv7 values in a
compact string format while maintaining their time-ordered sort
property.

The encode() function produces output padded with '=', while decode()
accepts both padded and unpadded input. Following the behavior of
other encoding types, decoding is case-insensitive.

Suggested-by: Sergey Prokhorenko &lt;sergeyprokhorenko@yahoo.com.au&gt;
Author: Andrey Borodin &lt;x4mmm@yandex-team.ru&gt;
Co-authored-by: Aleksander Alekseev &lt;aleksander@tigerdata.com&gt;
Reviewed-by: Masahiko Sawada &lt;sawada.mshk@gmail.com&gt;
Reviewed-by: Илья Чердаков &lt;i.cherdakov.pg@gmail.com&gt;
Reviewed-by: Chengxi Sun &lt;chengxisun92@gmail.com&gt;
Reviewed-by: Chao Li &lt;li.evan.chao@gmail.com&gt;
Discussion: https://postgr.es/m/CAJ7c6TOramr1UTLcyB128LWMqita1Y7%3Darq3KHaU%3Dqikf5yKOQ%40mail.gmail.com
</content>
</entry>
<entry>
<title>Add more tests with clause STORAGE on table and TOAST interactions</title>
<updated>2026-01-26T00:30:22Z</updated>
<author>
<name>Michael Paquier</name>
</author>
<published>2026-01-26T00:30:22Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=168765e5d42be7d3ef750e9e292e14ef94b489e1'/>
<id>urn:sha1:168765e5d42be7d3ef750e9e292e14ef94b489e1</id>
<content type='text'>
This commit adds more tests to cover STORAGE MAIN and EXTENDED, checking
how these use TOAST tables.  EXTENDED is already widely tested as the
default behavior, but there were no tests where the clause pattern is
directly specified.  STORAGE MAIN and its interactions with TOAST was
not covered at all.

This hole in the tests has been noticed for STORAGE MAIN (inline
compressible varlenas), where I have managed to break the backend
without the tests able to notice the breakage while playing with the
varlena structures.

Reviewed-by: Nikhil Kumar Veldanda &lt;veldanda.nikhilkumar17@gmail.com&gt;
Discussion: https://postgr.es/m/aXMdX1UTHnzYPkHk@paquier.xyz
</content>
</entry>
<entry>
<title>Force standard_conforming_strings to always be ON.</title>
<updated>2026-01-21T20:08:38Z</updated>
<author>
<name>Tom Lane</name>
</author>
<published>2026-01-21T20:08:38Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=45762084545ec14dbbe66ace1d69d7e89f8978ac'/>
<id>urn:sha1:45762084545ec14dbbe66ace1d69d7e89f8978ac</id>
<content type='text'>
Continuing to support this backwards-compatibility feature has
nontrivial costs; in particular it is potentially a security hazard
if an application somehow gets confused about which setting the
server is using.  We changed the default to ON fifteen years ago,
which seems like enough time for applications to have adapted.
Let's remove support for the legacy string syntax.

We should not remove the GUC altogether, since client-side code will
still test it, pg_dump scripts will attempt to set it to ON, etc.
Instead, just prevent it from being set to OFF.  There is precedent
for this approach (see commit de66987ad).

This patch does remove the related GUC escape_string_warning, however.
That setting does nothing when standard_conforming_strings is on,
so it's now useless.  We could leave it in place as a do-nothing
setting to avoid breaking clients that still set it, if there are any.
But it seems likely that any such client is also trying to turn off
standard_conforming_strings, so it'll need work anyway.

The client-side changes in this patch are pretty minimal, because even
though we are dropping the server's support, most of our clients still
need to be able to talk to older server versions.  We could remove
dead client code only once we disclaim compatibility with pre-v19
servers, which is surely years away.  One change of note is that
pg_dump/pg_dumpall now set standard_conforming_strings = on in their
source session, rather than accepting the source server's default.
This ensures that literals in view definitions and such will be
printed in a way that's acceptable to v19+.  In particular,
pg_upgrade will work transparently even if the source installation has
standard_conforming_strings = off.  (However, pg_restore will behave
the same as before if given an archive file containing
standard_conforming_strings = off.  Such an archive will not be safely
restorable into v19+, but we shouldn't break the ability to extract
valid data from it for use with an older server.)

Author: Tom Lane &lt;tgl@sss.pgh.pa.us&gt;
Discussion: https://postgr.es/m/3279216.1767072538@sss.pgh.pa.us
</content>
</entry>
<entry>
<title>Add HINT listing valid encodings to encode() and decode() errors.</title>
<updated>2025-11-20T00:14:02Z</updated>
<author>
<name>Fujii Masao</name>
</author>
<published>2025-11-20T00:14:02Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=99780da7209605bf9f226eac3eac30ab2bc9427c'/>
<id>urn:sha1:99780da7209605bf9f226eac3eac30ab2bc9427c</id>
<content type='text'>
This commit updates encode() and decode() so that when an invalid encoding
is specified, their error message includes a HINT listing all valid encodings.
This helps users quickly see which encodings are supported without needing
to consult the documentation.

Author: Shinya Sugamoto &lt;shinya34892@gmail.com&gt;
Reviewed-by: Chao Li &lt;lic@highgo.com&gt;
Reviewed-by: Daniel Gustafsson &lt;daniel@yesql.se&gt;
Reviewed-by: Masahiko Sawada &lt;sawada.mshk@gmail.com&gt;
Reviewed-by: Peter Eisentraut &lt;peter@eisentraut.org&gt;
Reviewed-by: Nathan Bossart &lt;nathandbossart@gmail.com&gt;
Reviewed-by: Fujii Masao &lt;masao.fujii@gmail.com&gt;
Discussion: https://postgr.es/m/CAAe3y+99sfPv8UDF1VM-rC1i5HBdqxUh=2HrbJJFm2+i=1OwOw@mail.gmail.com
</content>
</entry>
<entry>
<title>Optimize hex_encode() and hex_decode() using SIMD.</title>
<updated>2025-10-06T17:28:50Z</updated>
<author>
<name>Nathan Bossart</name>
</author>
<published>2025-10-06T17:28:50Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=ec8719ccbfcd78c6b40b5f2b94f60769f3bd08aa'/>
<id>urn:sha1:ec8719ccbfcd78c6b40b5f2b94f60769f3bd08aa</id>
<content type='text'>
The hex_encode() and hex_decode() functions serve as the workhorses
for hexadecimal data for bytea's text format conversion functions,
and some workloads are sensitive to their performance.  This commit
adds new implementations that use routines from port/simd.h, which
testing indicates are much faster for larger inputs.  For small or
invalid inputs, we fall back on the existing scalar versions.
Since we are using port/simd.h, these optimizations apply to both
x86-64 and AArch64.

Author: Nathan Bossart &lt;nathandbossart@gmail.com&gt;
Co-authored-by: Chiranmoy Bhattacharya &lt;chiranmoy.bhattacharya@fujitsu.com&gt;
Co-authored-by: Susmitha Devanga &lt;devanga.susmitha@fujitsu.com&gt;
Reviewed-by: John Naylor &lt;johncnaylorls@gmail.com&gt;
Discussion: https://postgr.es/m/aLhVWTRy0QPbW2tl%40nathan
</content>
</entry>
<entry>
<title>Add support for base64url encoding and decoding</title>
<updated>2025-09-20T21:19:32Z</updated>
<author>
<name>Daniel Gustafsson</name>
</author>
<published>2025-09-20T21:19:32Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=e1d917182c1953b16b32a39ed2fe38e3d0823047'/>
<id>urn:sha1:e1d917182c1953b16b32a39ed2fe38e3d0823047</id>
<content type='text'>
This adds support for base64url encoding and decoding, a base64
variant which is safe to use in filenames and URLs.  base64url
replaces '+' in the base64 alphabet with '-' and '/' with '_',
thus making it safe for URL addresses and file systems.

Support for base64url was originally suggested by Przemysław Sztoch.

Author: Florents Tselai &lt;florents.tselai@gmail.com&gt;
Reviewed-by: Aleksander Alekseev &lt;aleksander@timescale.com&gt;
Reviewed-by: David E. Wheeler &lt;david@justatheory.com&gt;
Reviewed-by: Masahiko Sawada &lt;sawada.mshk@gmail.com&gt;
Reviewed-by: Daniel Gustafsson &lt;daniel@yesql.se&gt;
Reviewed-by: Chao Li (Evan) &lt;li.evan.chao@gmail.com&gt;
Discussion: https://postgr.es/m/70f2b6a8-486a-4fdb-a951-84cef35e22ab@sztoch.pl
</content>
</entry>
<entry>
<title>Amend recent fix for SIMILAR TO regex conversion.</title>
<updated>2025-09-13T20:55:51Z</updated>
<author>
<name>Tom Lane</name>
</author>
<published>2025-09-13T20:55:51Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=cdf7feb96562071f15ceb070272d7e84246d943d'/>
<id>urn:sha1:cdf7feb96562071f15ceb070272d7e84246d943d</id>
<content type='text'>
Commit e3ffc3e91 fixed the translation of character classes in
SIMILAR TO regular expressions.  Unfortunately the fix broke a corner
case: if there is an escape character right after the opening bracket
(for example in "[\q]"), a closing bracket right after the escape
sequence would not be seen as closing the character class.

There were two more oversights: a backslash or a nested opening bracket
right at the beginning of a character class should remove the special
meaning from any following caret or closing bracket.

This bug suggests that this code needs to be more readable, so also
rename the variables "charclass_depth" and "charclass_start" to
something more meaningful, rewrite an "if" cascade to be more
consistent, and improve the commentary.

Reported-by: Dominique Devienne &lt;ddevienne@gmail.com&gt;
Reported-by: Stephan Springl &lt;springl-psql@bfw-online.de&gt;
Author: Laurenz Albe &lt;laurenz.albe@cybertec.at&gt;
Reviewed-by: Tom Lane &lt;tgl@sss.pgh.pa.us&gt;
Discussion: https://postgr.es/m/CAFCRh-8NwJd0jq6P=R3qhHyqU7hw0BTor3W0SvUcii24et+zAw@mail.gmail.com
Backpatch-through: 13
</content>
</entry>
<entry>
<title>Add regression test for short varlenas saved in TOAST relations</title>
<updated>2025-08-06T08:22:03Z</updated>
<author>
<name>Michael Paquier</name>
</author>
<published>2025-08-06T08:22:03Z</published>
<link rel='alternate' type='text/html' href='http://git.postgresql.org/cgit/postgresql.git/commit/?id=225ebfe30a1ae9fda74f3d8f98ea6fa511b60624'/>
<id>urn:sha1:225ebfe30a1ae9fda74f3d8f98ea6fa511b60624</id>
<content type='text'>
toast_save_datum() has for a very long time some code able to handle
short varlenas (values up to 126 bytes reduced to a 1-byte header),
converting such varlenas to an external on-disk TOAST pointer with the
value saved uncompressed in the secondary TOAST relation.

There was zero coverage for this code path.  This commit adds a test
able to exercise it, relying on two external attributes, one with a low
toast_tuple_target, so as it is possible to trigger the threshold for
the insertion of short varlenas into the TOAST relation.

Author: Nikhil Kumar Veldanda &lt;veldanda.nikhilkumar17@gmail.com&gt;
Co-authored-by: Michael Paquier &lt;michael@paquier.xyz&gt;
Discussion: https://postgr.es/m/aJAl7-NvIk0kZByz@paquier.xyz
</content>
</entry>
</feed>
