- Notifications
You must be signed in to change notification settings - Fork4.9k
Commitf521ef0
committed
Fix CheckAttributeType's handling of collations for ranges.
Commitfc76958 changed CheckAttributeType to recurse into ranges,but made it pass down the wrong collation (always InvalidOid, sinceranges as such have no collation). This would result in guaranteedfailure when considering a range type whose subtype is collatable.Embarrassingly, we lack any regression tests that would expose sucha problem (but fortunately, somebody noticed before we shipped thisbug in any release).Fix it to pass down the range's subtype collation property instead,and add some regression test cases to exercise collatable-subtyperanges a bit more. Back-patch to all supported branches, as theprevious patch was.Report and patch by Julien Rouhaud, test cases tweaked by meDiscussion:https://postgr.es/m/CAOBaU_aBWqNweiGUFX0guzBKkcfJ8mnnyyGC_KBQmO12Mj5f_A@mail.gmail.com1 parent5d60df8 commitf521ef0
File tree
6 files changed
+148
-3
lines changed- src
- backend
- catalog
- utils/cache
- include/utils
- test/regress
- expected
- sql
6 files changed
+148
-3
lines changedLines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
566 | 566 |
| |
567 | 567 |
| |
568 | 568 |
| |
569 |
| - | |
| 569 | + | |
| 570 | + | |
570 | 571 |
| |
571 | 572 |
| |
572 | 573 |
| |
|
Lines changed: 26 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
2968 | 2968 |
| |
2969 | 2969 |
| |
2970 | 2970 |
| |
| 2971 | + | |
| 2972 | + | |
| 2973 | + | |
| 2974 | + | |
| 2975 | + | |
| 2976 | + | |
| 2977 | + | |
| 2978 | + | |
| 2979 | + | |
| 2980 | + | |
| 2981 | + | |
| 2982 | + | |
| 2983 | + | |
| 2984 | + | |
| 2985 | + | |
| 2986 | + | |
| 2987 | + | |
| 2988 | + | |
| 2989 | + | |
| 2990 | + | |
| 2991 | + | |
| 2992 | + | |
| 2993 | + | |
| 2994 | + | |
| 2995 | + | |
| 2996 | + |
Lines changed: 1 addition & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
154 | 154 |
| |
155 | 155 |
| |
156 | 156 |
| |
| 157 | + | |
157 | 158 |
| |
158 | 159 |
| |
159 | 160 |
| |
|
Lines changed: 88 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
564 | 564 |
| |
565 | 565 |
| |
566 | 566 |
| |
567 |
| - | |
| 567 | + | |
568 | 568 |
| |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 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 | + | |
569 | 656 |
| |
570 | 657 |
| |
571 | 658 |
| |
|
Lines changed: 2 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
81 | 81 |
| |
82 | 82 |
| |
83 | 83 |
| |
| 84 | + | |
84 | 85 |
| |
85 | 86 |
| |
86 | 87 |
| |
| |||
162 | 163 |
| |
163 | 164 |
| |
164 | 165 |
| |
| 166 | + | |
165 | 167 |
| |
166 | 168 |
| |
167 | 169 |
| |
|
Lines changed: 29 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
144 | 144 |
| |
145 | 145 |
| |
146 | 146 |
| |
147 |
| - | |
| 147 | + | |
148 | 148 |
| |
149 | 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 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
150 | 178 |
| |
151 | 179 |
| |
152 | 180 |
| |
|
0 commit comments
Comments
(0)