Skip to content

Report unsupported ALTER CONSTRAINT explicitly - #8808

Draft
ibrahim halatci (ihalatci) wants to merge 4 commits into
mainfrom
ihalatci-pg19-explicit-alter-table-errors
Draft

ibrahim halatci (ihalatci) wants to merge 4 commits into
mainfrom
ihalatci-pg19-explicit-alter-table-errors

Conversation

@ihalatci

@ihalatci ibrahim halatci (ihalatci) commented Aug 27, 2026 •

Copy link
Copy Markdown
Contributor

Draft fix for #8758 after the PostgreSQL 19 Beta 4 reassessment.

Beta 4 reverted partition MERGE/SPLIT, so this PR should contain only the retained ALTER TABLE ... ALTER CONSTRAINT guardrail:

  • return a stable FEATURE_NOT_SUPPORTED error for distributed, reference, and Citus-local tables;
  • explain that constraint property changes are not propagated to shards;
  • preserve ordinary PostgreSQL local-table behavior;
  • cover PG19 CHECK constraint enforceability and supported-version rejection behavior.

Before review, rebase onto current main and remove unrelated DETACH PARTITION error-code changes unless they are split into a separately justified PR.

@codecov

codecov Bot commented Aug 27, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 25.00000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 88.77%. Comparing base (991faa8) to head (eaacf5e).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8808      +/-   ##
==========================================
- Coverage   88.77%   88.77%   -0.01%     
==========================================
  Files         290      290              
  Lines       65132    65134       +2     
  Branches     8223     8222       -1     
==========================================
+ Hits        57823    57824       +1     
- Misses       4936     4937       +1     
  Partials     2373     2373              
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Make ALTER TABLE ... ALTER CONSTRAINT fail with a stable FEATURE_NOT_SUPPORTED error and a detail explaining that Citus does not propagate constraint property changes to shards. Also tag the related DETACH PARTITION unsupported paths with FEATURE_NOT_SUPPORTED.

Refs #8758

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 61c1aeb4-1b56-4313-a35e-d65b59a557de
Refs #8758

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 61c1aeb4-1b56-4313-a35e-d65b59a557de
Refs #8758

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 61c1aeb4-1b56-4313-a35e-d65b59a557de
Refs #8758

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

Copilot-Session: 61c1aeb4-1b56-4313-a35e-d65b59a557de
@ihalatci
ibrahim halatci (ihalatci) force-pushed the ihalatci-pg19-explicit-alter-table-errors branch from d874fa3 to eaacf5e Compare September 28, 2026 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants