aboutsummaryrefslogtreecommitdiff
path: root/src/backend/commands/dbcommands.c
diff options
context:
space:
mode:
authorDavid Rowley <drowley@postgresql.org>2024-08-15 13:10:25 +1200
committerDavid Rowley <drowley@postgresql.org>2024-08-15 13:10:25 +1200
commit80ffcb842748f0b8ccf8b24c5c3b2500755d2dcd (patch)
treeb645ab68d854b1e15013b40073db4c5dd759a64c /src/backend/commands/dbcommands.c
parentef6e028f05b3e4ab23c5edfdfff457e0d2a649f6 (diff)
downloadpostgresql-80ffcb842748f0b8ccf8b24c5c3b2500755d2dcd.tar.gz
postgresql-80ffcb842748f0b8ccf8b24c5c3b2500755d2dcd.zip
Improve ALTER PUBLICATION validation and error messages
Attempting to add a system column for a table to an existing publication would result in the not very intuitive error message of: ERROR: negative bitmapset member not allowed Here we improve that to have it display the same error message as a user would see if they tried adding a system column for a table when adding it to the publication in the first place. Doing this requires making the function which validates the list of columns an extern function. The signature of the static function wasn't an ideal external API as it made the code more complex than it needed to be. Here we adjust the function to have it populate a Bitmapset of attribute numbers. Doing it this way allows code simplification. There was no particular bug here other than the weird error message, so no backpatch. Bug: #18558 Reported-by: Alexander Lakhin <exclusion@gmail.com> Author: Peter Smith, David Rowley Discussion: https://postgr.es/m/18558-411bc81b03592125@postgresql.org
Diffstat (limited to 'src/backend/commands/dbcommands.c')
0 files changed, 0 insertions, 0 deletions