forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitba9f665
committed
Really fix the ambiguity in REFRESH MATERIALIZED VIEW CONCURRENTLY.
Rather than trying to pick table aliases that won't conflict withany possible user-defined matview column name, adjust the queries'syntax so that the aliases are only used in places where they can't bemistaken for column names. Mostly this consists of writing "alias.*"not just "alias", which adds clarity for humans as well as machines.We do have the issue that "SELECT alias.*" acts differently from"SELECT alias", but we can use the same hack ruleutils.c uses forwhole-row variables in SELECT lists: write "alias.*::compositetype".We might as well revert to the original aliases after doing this;they're a bit easier to read.Like75d66d1, back-patch to all supported branches.Discussion:https://postgr.es/m/2488325.1628261320@sss.pgh.pa.us1 parentda188b9 commitba9f665
File tree
3 files changed
+47
-24
lines changed- src
- backend/commands
- test/regress
- expected
- sql
3 files changed
+47
-24
lines changedLines changed: 29 additions & 22 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
525 | 525 |
| |
526 | 526 |
| |
527 | 527 |
| |
| 528 | + | |
528 | 529 |
| |
529 |
| - | |
530 |
| - | |
| 530 | + | |
| 531 | + | |
| 532 | + | |
| 533 | + | |
531 | 534 |
| |
532 | 535 |
| |
533 | 536 |
| |
| |||
615 | 618 |
| |
616 | 619 |
| |
617 | 620 |
| |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
618 | 625 |
| |
619 | 626 |
| |
620 | 627 |
| |
621 |
| - | |
622 |
| - | |
623 |
| - | |
624 |
| - | |
625 |
| - | |
626 |
| - | |
627 |
| - | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
628 | 635 |
| |
629 | 636 |
| |
630 | 637 |
| |
| |||
651 | 658 |
| |
652 | 659 |
| |
653 | 660 |
| |
654 |
| - | |
655 |
| - | |
656 |
| - | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
657 | 664 |
| |
658 | 665 |
| |
659 | 666 |
| |
| |||
745 | 752 |
| |
746 | 753 |
| |
747 | 754 |
| |
748 |
| - | |
| 755 | + | |
749 | 756 |
| |
750 |
| - | |
| 757 | + | |
751 | 758 |
| |
752 | 759 |
| |
753 | 760 |
| |
| |||
775 | 782 |
| |
776 | 783 |
| |
777 | 784 |
| |
778 |
| - | |
779 |
| - | |
| 785 | + | |
| 786 | + | |
780 | 787 |
| |
781 | 788 |
| |
782 | 789 |
| |
| |||
802 | 809 |
| |
803 | 810 |
| |
804 | 811 |
| |
805 |
| - | |
806 |
| - | |
807 |
| - | |
808 |
| - | |
| 812 | + | |
| 813 | + | |
| 814 | + | |
| 815 | + | |
809 | 816 |
| |
810 | 817 |
| |
811 | 818 |
| |
812 | 819 |
| |
813 | 820 |
| |
814 | 821 |
| |
815 | 822 |
| |
816 |
| - | |
817 |
| - | |
| 823 | + | |
| 824 | + | |
818 | 825 |
| |
819 | 826 |
| |
820 | 827 |
| |
|
Lines changed: 9 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
551 | 551 |
| |
552 | 552 |
| |
553 | 553 |
| |
554 |
| - | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
555 | 563 |
| |
556 | 564 |
| |
557 | 565 |
| |
|
Lines changed: 9 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
211 | 211 |
| |
212 | 212 |
| |
213 | 213 |
| |
214 |
| - | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
215 | 223 |
| |
216 | 224 |
| |
217 | 225 |
| |
|
0 commit comments
Comments
(0)