From fa39617a64d4134c63b3f62ae12b0268542a79e5 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Fri, 24 Nov 2017 00:29:20 -0500 Subject: [PATCH] Fix unstable regression test added by commits 59b71c6fe et al. The query didn't really have a preferred index, leading to platform- specific choices of which one to use. Adjust it to make sure tenk1_hundred is always chosen. Per buildfarm. --- src/test/regress/expected/aggregates.out | 6 +++--- src/test/regress/sql/aggregates.sql | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/test/regress/expected/aggregates.out b/src/test/regress/expected/aggregates.out index 0f18a392e2..e768b1fe6d 100644 --- a/src/test/regress/expected/aggregates.out +++ b/src/test/regress/expected/aggregates.out @@ -1994,7 +1994,7 @@ CREATE AGGREGATE balk( STYPE = int8, "PARALLEL" = SAFE, INITCOND = '0'); -SELECT balk(1) FROM tenk1; +SELECT balk(hundred) FROM tenk1; balk ------ @@ -2030,7 +2030,7 @@ SET LOCAL parallel_setup_cost=0; SET LOCAL max_parallel_workers_per_gather=4; SET LOCAL enable_indexscan = off; SET LOCAL enable_bitmapscan = off; -EXPLAIN (COSTS OFF) SELECT balk(1) FROM tenk1; +EXPLAIN (COSTS OFF) SELECT balk(hundred) FROM tenk1; QUERY PLAN ---------------------------------------------- Finalize Aggregate @@ -2040,7 +2040,7 @@ EXPLAIN (COSTS OFF) SELECT balk(1) FROM tenk1; -> Parallel Seq Scan on tenk1 (5 rows) -SELECT balk(1) FROM tenk1; +SELECT balk(hundred) FROM tenk1; balk ------ diff --git a/src/test/regress/sql/aggregates.sql b/src/test/regress/sql/aggregates.sql index 7ddc4da177..cb28f4cffe 100644 --- a/src/test/regress/sql/aggregates.sql +++ b/src/test/regress/sql/aggregates.sql @@ -860,7 +860,7 @@ CREATE AGGREGATE balk( "PARALLEL" = SAFE, INITCOND = '0'); -SELECT balk(1) FROM tenk1; +SELECT balk(hundred) FROM tenk1; ROLLBACK; @@ -896,7 +896,7 @@ SET LOCAL max_parallel_workers_per_gather=4; SET LOCAL enable_indexscan = off; SET LOCAL enable_bitmapscan = off; -EXPLAIN (COSTS OFF) SELECT balk(1) FROM tenk1; -SELECT balk(1) FROM tenk1; +EXPLAIN (COSTS OFF) SELECT balk(hundred) FROM tenk1; +SELECT balk(hundred) FROM tenk1; ROLLBACK; -- 2.40.0