forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit75839fc
committed
Fix assertion failure with ALTER TABLE ATTACH PARTITION and indexes
Using ALTER TABLE ATTACH PARTITION causes an assertion failure whenattempting to work on a partitioned index, because partitioned indexescannot have partition bounds.The grammar of ALTER TABLE ATTACH PARTITION requires partition bounds,but not ALTER INDEX, so mixing ALTER TABLE with partitioned indexes isconfusing. Hence, on HEAD, prevent ALTER TABLE to attach a partition ifthe relation involved is a partitioned index. On back-branches, asapplications may rely on the existing behavior, just remove theculprit assertion.Reported-by: Alexander LakhinAuthor: Amit Langote, Michael PaquierDiscussion:https://postgr.es/m/16276-5cd1dcc8fb8be7b5@postgresql.orgBackpatch-through: 111 parent53fc42c commit75839fc
File tree
3 files changed
+26
-1
lines changed- src
- backend/parser
- test/regress
- expected
- sql
3 files changed
+26
-1
lines changedLines changed: 0 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
3563 | 3563 |
| |
3564 | 3564 |
| |
3565 | 3565 |
| |
3566 |
| - | |
3567 | 3566 |
| |
3568 | 3567 |
| |
3569 | 3568 |
| |
|
Lines changed: 16 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
94 | 94 |
| |
95 | 95 |
| |
96 | 96 |
| |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
97 | 113 |
| |
98 | 114 |
| |
99 | 115 |
| |
|
Lines changed: 10 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
46 | 46 |
| |
47 | 47 |
| |
48 | 48 |
| |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
49 | 59 |
| |
50 | 60 |
| |
51 | 61 |
| |
|
0 commit comments
Comments
(0)