aboutsummaryrefslogtreecommitdiff
path: root/src/test/regress/expected/union.out
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/regress/expected/union.out')
-rw-r--r--src/test/regress/expected/union.out32
1 files changed, 12 insertions, 20 deletions
diff --git a/src/test/regress/expected/union.out b/src/test/regress/expected/union.out
index 882017afc9a..0f93a842e4e 100644
--- a/src/test/regress/expected/union.out
+++ b/src/test/regress/expected/union.out
@@ -412,16 +412,17 @@ set enable_hashagg to off;
explain (costs off)
select count(*) from
( select unique1 from tenk1 union select fivethous from tenk1 ) ss;
- QUERY PLAN
-----------------------------------------------------------------------
+ QUERY PLAN
+----------------------------------------------------------------
Aggregate
-> Unique
- -> Sort
+ -> Merge Append
Sort Key: tenk1.unique1
- -> Append
- -> Index Only Scan using tenk1_unique1 on tenk1
+ -> Index Only Scan using tenk1_unique1 on tenk1
+ -> Sort
+ Sort Key: tenk1_1.fivethous
-> Seq Scan on tenk1 tenk1_1
-(7 rows)
+(8 rows)
select count(*) from
( select unique1 from tenk1 union select fivethous from tenk1 ) ss;
@@ -950,16 +951,9 @@ select except select;
-- check hashed implementation
set enable_hashagg = true;
set enable_sort = false;
-explain (costs off)
-select from generate_series(1,5) union select from generate_series(1,3);
- QUERY PLAN
-----------------------------------------------------------------
- HashAggregate
- -> Append
- -> Function Scan on generate_series
- -> Function Scan on generate_series generate_series_1
-(4 rows)
-
+-- We've no way to check hashed UNION as the empty pathkeys in the Append are
+-- fine to make use of Unique, which is cheaper than HashAggregate and we've
+-- no means to disable Unique.
explain (costs off)
select from generate_series(1,5) intersect select from generate_series(1,3);
QUERY PLAN
@@ -972,10 +966,6 @@ select from generate_series(1,5) intersect select from generate_series(1,3);
-> Function Scan on generate_series generate_series_1
(6 rows)
-select from generate_series(1,5) union select from generate_series(1,3);
---
-(1 row)
-
select from generate_series(1,5) union all select from generate_series(1,3);
--
(8 rows)
@@ -1081,6 +1071,7 @@ INSERT INTO t2 VALUES ('ab'), ('xy');
set enable_seqscan = off;
set enable_indexscan = on;
set enable_bitmapscan = off;
+set enable_sort = off;
explain (costs off)
SELECT * FROM
(SELECT a || b AS ab FROM t1
@@ -1162,6 +1153,7 @@ explain (costs off)
reset enable_seqscan;
reset enable_indexscan;
reset enable_bitmapscan;
+reset enable_sort;
-- This simpler variant of the above test has been observed to fail differently
create table events (event_id int primary key);
create table other_events (event_id int primary key);