| From: | Michael Paquier <michael(at)paquier(dot)xyz> |
|---|---|
| To: | pgsql-committers(at)lists(dot)postgresql(dot)org |
| Subject: | pgsql: Improve error code and messages for some SQL-reachable code path |
| Date: | 2026-09-22 10:49:01 |
| Message-ID: | E1x8y3Z-00000000lRi-2vcH@gemulon.postgresql.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-committers |
Improve error code and messages for some SQL-reachable code paths
The error code paths adjusted in this commit are reachable via SQL
functions that are documented. Previously, they generated an internal
error code, causing the messages to not be translated. They are now
upgraded with a suitable error code.
Note the extra consistency in the three typmod errors, and the tweaks in
acldefault_sql() to show correctly non-printable characters.
Author: Alexander Lakhin <exclusion(at)gmail(dot)com>
Reviewed-by: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Discussion: https://postgr.es/m/94ac928b-8370-4db5-ada5-579a9ebc089d@gmail.com
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/e8a3ee5b1974e2de40e8cf8dac28f2ef500a2950
Modified Files
--------------
src/backend/catalog/objectaddress.c | 4 +++-
src/backend/commands/tablecmds.c | 1 +
src/backend/parser/parse_utilcmd.c | 6 ++++--
src/backend/storage/ipc/shmem.c | 4 +++-
src/backend/utils/adt/acl.c | 11 ++++++++++-
src/backend/utils/adt/timestamp.c | 12 +++++++++---
src/pl/plpgsql/src/pl_gram.y | 4 +++-
7 files changed, 33 insertions(+), 9 deletions(-)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Nathan Bossart | 2026-09-22 17:44:50 | pgsql: Convert ParallelBitmapHeapState->state to an atomic variable. |
| Previous Message | Peter Eisentraut | 2026-09-22 10:12:38 | pgsql: Update .abi-compliance-history for parallel GIN index build fix |