Commit f64554b
committed
Handle OID column inheritance correctly in ALTER TABLE ... INHERIT.
Inheritance operations must treat the OID column, if any, much like
regular user columns. But MergeAttributesIntoExisting() neglected to
do that, leading to weird results after a table with OIDs is associated
to a parent with OIDs via ALTER TABLE ... INHERIT.
Report and patch by Amit Langote, reviewed by Ashutosh Bapat, some
adjustments by me. It's been broken all along, so back-patch to
all supported branches.
Discussion: https://postgr.es/m/cb13cfe7-a48c-5720-c383-bb843ab28298@lab.ntt.co.jp1 parent 6e5de70 commit f64554b
File tree
3 files changed
+108
-0
lines changed- src
- backend/commands
- test/regress
- expected
- sql
3 files changed
+108
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10329 | 10329 | | |
10330 | 10330 | | |
10331 | 10331 | | |
| 10332 | + | |
| 10333 | + | |
| 10334 | + | |
| 10335 | + | |
| 10336 | + | |
| 10337 | + | |
| 10338 | + | |
| 10339 | + | |
| 10340 | + | |
| 10341 | + | |
| 10342 | + | |
| 10343 | + | |
| 10344 | + | |
| 10345 | + | |
| 10346 | + | |
| 10347 | + | |
| 10348 | + | |
| 10349 | + | |
| 10350 | + | |
| 10351 | + | |
| 10352 | + | |
| 10353 | + | |
| 10354 | + | |
| 10355 | + | |
| 10356 | + | |
| 10357 | + | |
| 10358 | + | |
| 10359 | + | |
| 10360 | + | |
| 10361 | + | |
| 10362 | + | |
| 10363 | + | |
| 10364 | + | |
10332 | 10365 | | |
10333 | 10366 | | |
10334 | 10367 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
612 | 612 | | |
613 | 613 | | |
614 | 614 | | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
| 645 | + | |
| 646 | + | |
| 647 | + | |
| 648 | + | |
| 649 | + | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
615 | 664 | | |
616 | 665 | | |
617 | 666 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
145 | 145 | | |
146 | 146 | | |
147 | 147 | | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
148 | 174 | | |
149 | 175 | | |
150 | 176 | | |
| |||
0 commit comments