aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2011-10-08 23:45:58 -0400
committerTom Lane <tgl@sss.pgh.pa.us>2011-10-08 23:45:58 -0400
commit45401c1c25fe1ef14bf68089de86bcb5cce9f453 (patch)
tree4f6854324259ba92c858bb09c9af3c4fdc5e206c
parentc78d8cd1464bc6b69fdc72f9ce51407c89554ece (diff)
downloadpostgresql-45401c1c25fe1ef14bf68089de86bcb5cce9f453.tar.gz
postgresql-45401c1c25fe1ef14bf68089de86bcb5cce9f453.zip
Prevent index-only scans in stats regression test.
This bollixes the test because it's expecting to see the idx_tup_fetch counter increase, which won't happen if heap fetches were avoided by use of an index-only scan. Per buildfarm results. While at it, let's just make sure that enable_seqscan and enable_indexscan are ON for this test ...
-rw-r--r--src/test/regress/expected/stats.out5
-rw-r--r--src/test/regress/sql/stats.sql6
2 files changed, 11 insertions, 0 deletions
diff --git a/src/test/regress/expected/stats.out b/src/test/regress/expected/stats.out
index 00811e2145f..56bace1187b 100644
--- a/src/test/regress/expected/stats.out
+++ b/src/test/regress/expected/stats.out
@@ -11,6 +11,11 @@ SHOW track_counts; -- must be on
on
(1 row)
+-- ensure that both seqscan and indexscan plans are allowed
+SET enable_seqscan TO on;
+SET enable_indexscan TO on;
+-- for the moment, we don't want index-only scans here
+SET enable_indexonlyscan TO off;
-- wait to let any prior tests finish dumping out stats;
-- else our messages might get lost due to contention
SELECT pg_sleep(2.0);
diff --git a/src/test/regress/sql/stats.sql b/src/test/regress/sql/stats.sql
index 4a72a949f29..bb349b2dfa6 100644
--- a/src/test/regress/sql/stats.sql
+++ b/src/test/regress/sql/stats.sql
@@ -8,6 +8,12 @@
-- conditio sine qua non
SHOW track_counts; -- must be on
+-- ensure that both seqscan and indexscan plans are allowed
+SET enable_seqscan TO on;
+SET enable_indexscan TO on;
+-- for the moment, we don't want index-only scans here
+SET enable_indexonlyscan TO off;
+
-- wait to let any prior tests finish dumping out stats;
-- else our messages might get lost due to contention
SELECT pg_sleep(2.0);