forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit2d1d96b
committed
Teach the system how to use hashing for UNION. (INTERSECT/EXCEPT will follow,
but seem like a separate patch since most of the remaining work is on theexecutor side.) I took the opportunity to push selection of the groupingoperators for set operations into the parser where it belongs. Otherwise thisis just a small exercise in making prepunion.c consider both alternatives.As with the recent DISTINCT patch, this means we can UNION on datatypes thatcan hash but not sort, and it means that UNION without ORDER BY is no longercertain to produce sorted output.1 parent3d40d5e commit2d1d96b
File tree
20 files changed
+462
-212
lines changed- src
- backend
- catalog
- nodes
- optimizer
- plan
- prep
- util
- parser
- include
- catalog
- nodes
- optimizer
- parser
- test/regress
- expected
- sql
20 files changed
+462
-212
lines changedLines changed: 10 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
1597 | 1597 |
| |
1598 | 1598 |
| |
1599 | 1599 |
| |
| 1600 | + | |
| 1601 | + | |
| 1602 | + | |
| 1603 | + | |
| 1604 | + | |
| 1605 | + | |
| 1606 | + | |
| 1607 | + | |
| 1608 | + | |
1600 | 1609 |
| |
1601 | 1610 |
| |
1602 | 1611 |
| |
|
Lines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
15 | 15 |
| |
16 | 16 |
| |
17 | 17 |
| |
18 |
| - | |
| 18 | + | |
19 | 19 |
| |
20 | 20 |
| |
21 | 21 |
| |
| |||
1943 | 1943 |
| |
1944 | 1944 |
| |
1945 | 1945 |
| |
| 1946 | + | |
1946 | 1947 |
| |
1947 | 1948 |
| |
1948 | 1949 |
| |
|
Lines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
18 | 18 |
| |
19 | 19 |
| |
20 | 20 |
| |
21 |
| - | |
| 21 | + | |
22 | 22 |
| |
23 | 23 |
| |
24 | 24 |
| |
| |||
839 | 839 |
| |
840 | 840 |
| |
841 | 841 |
| |
| 842 | + | |
842 | 843 |
| |
843 | 844 |
| |
844 | 845 |
| |
|
Lines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
1780 | 1780 |
| |
1781 | 1781 |
| |
1782 | 1782 |
| |
| 1783 | + | |
1783 | 1784 |
| |
1784 | 1785 |
| |
1785 | 1786 |
| |
|
Lines changed: 2 additions & 1 deletion
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
232 | 232 |
| |
233 | 233 |
| |
234 | 234 |
| |
| 235 | + | |
235 | 236 |
| |
236 | 237 |
| |
237 | 238 |
| |
|
Lines changed: 6 additions & 104 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
8 | 8 |
| |
9 | 9 |
| |
10 | 10 |
| |
11 |
| - | |
| 11 | + | |
12 | 12 |
| |
13 | 13 |
| |
14 | 14 |
| |
| |||
68 | 68 |
| |
69 | 69 |
| |
70 | 70 |
| |
71 |
| - | |
72 |
| - | |
73 |
| - | |
74 |
| - | |
75 | 71 |
| |
76 | 72 |
| |
77 | 73 |
| |
| |||
784 | 780 |
| |
785 | 781 |
| |
786 | 782 |
| |
787 |
| - | |
788 |
| - | |
789 |
| - | |
790 |
| - | |
| 783 | + | |
| 784 | + | |
| 785 | + | |
791 | 786 |
| |
792 | 787 |
| |
793 | 788 |
| |
| |||
818 | 813 |
| |
819 | 814 |
| |
820 | 815 |
| |
821 |
| - | |
| 816 | + | |
| 817 | + | |
822 | 818 |
| |
823 | 819 |
| |
824 | 820 |
| |
| |||
1714 | 1710 |
| |
1715 | 1711 |
| |
1716 | 1712 |
| |
1717 |
| - | |
1718 |
| - | |
1719 |
| - | |
1720 |
| - | |
1721 |
| - | |
1722 |
| - | |
1723 |
| - | |
1724 |
| - | |
1725 |
| - | |
1726 |
| - | |
1727 |
| - | |
1728 |
| - | |
1729 |
| - | |
1730 |
| - | |
1731 |
| - | |
1732 |
| - | |
1733 |
| - | |
1734 |
| - | |
1735 |
| - | |
1736 |
| - | |
1737 |
| - | |
1738 |
| - | |
1739 |
| - | |
1740 |
| - | |
1741 |
| - | |
1742 |
| - | |
1743 |
| - | |
1744 |
| - | |
1745 |
| - | |
1746 |
| - | |
1747 |
| - | |
1748 |
| - | |
1749 |
| - | |
1750 |
| - | |
1751 |
| - | |
1752 |
| - | |
1753 |
| - | |
1754 |
| - | |
1755 |
| - | |
1756 |
| - | |
1757 |
| - | |
1758 |
| - | |
1759 |
| - | |
1760 |
| - | |
1761 |
| - | |
1762 |
| - | |
1763 |
| - | |
1764 |
| - | |
1765 |
| - | |
1766 |
| - | |
1767 |
| - | |
1768 |
| - | |
1769 |
| - | |
1770 |
| - | |
1771 |
| - | |
1772 |
| - | |
1773 |
| - | |
1774 |
| - | |
1775 |
| - | |
1776 |
| - | |
1777 |
| - | |
1778 |
| - | |
1779 |
| - | |
1780 |
| - | |
1781 |
| - | |
1782 |
| - | |
1783 |
| - | |
1784 |
| - | |
1785 |
| - | |
1786 |
| - | |
1787 |
| - | |
1788 |
| - | |
1789 |
| - | |
1790 |
| - | |
1791 |
| - | |
1792 |
| - | |
1793 |
| - | |
1794 |
| - | |
1795 |
| - | |
1796 |
| - | |
1797 |
| - | |
1798 |
| - | |
1799 |
| - | |
1800 |
| - | |
1801 |
| - | |
1802 |
| - | |
1803 |
| - | |
1804 |
| - | |
1805 |
| - | |
1806 |
| - | |
1807 |
| - | |
1808 |
| - | |
1809 |
| - | |
1810 |
| - | |
1811 | 1713 |
| |
1812 | 1714 |
| |
1813 | 1715 |
| |
|
0 commit comments
Comments
(0)