Skip to content

PostgreSQL: Support NO INHERIT in ALTER TABLE - #2814

Merged
LucaCappelletti94 merged 2 commits into
upstream/pg-alter-table-inheritfrom
upstream/pg-alter-table-no-inherit
Nov 4, 2026
Merged

LucaCappelletti94 merged 2 commits into
upstream/pg-alter-table-inheritfrom
upstream/pg-alter-table-no-inherit

Conversation

@LucaCappelletti94

Copy link
Copy Markdown
Contributor

ALTER TABLE c NO INHERIT parent failed with Expected: ADD, RENAME, PARTITION, SWAP, DROP, REPLICA IDENTITY, SET, or SET TBLPROPERTIES after ALTER TABLE, found: NO, although PostgreSQL documents it as an action of ALTER TABLE and ALTER FOREIGN TABLE.

It now parses into AlterTableOperation::NoInherit, the counterpart of Inherit, holding the parent table name. NO is otherwise not a valid start of an ALTER TABLE action, so NO followed by anything but INHERIT reports Expected: INHERIT.

@codecov-commenter

codecov-commenter commented Nov 4, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (upstream/pg-alter-table-inherit@6a0428e). Learn more about missing BASE report.

Additional details and impacted files
@@                        Coverage Diff                         @@
##             upstream/pg-alter-table-inherit    #2814   +/-   ##
==================================================================
  Coverage                                   ?   83.10%           
==================================================================
  Files                                      ?       42           
  Lines                                      ?    36294           
  Branches                                   ?    36294           
==================================================================
  Hits                                       ?    30163           
  Misses                                     ?     2636           
  Partials                                   ?     3495           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@s5dsn-eqee s5dsn-eqee left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@LucaCappelletti94
LucaCappelletti94 force-pushed the upstream/pg-alter-table-no-inherit branch from 78a6ed7 to 10d5f91 Compare November 4, 2026 11:39
@LucaCappelletti94

Copy link
Copy Markdown
Contributor Author

Thank you @s5dsn-eqee for reviewing this stack, I will attempt to merge it now.

cc @alamb

@LucaCappelletti94
LucaCappelletti94 added this pull request to the merge queue Nov 4, 2026
Merged via the queue into main with commit d1c1790 Nov 4, 2026
10 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants