Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitbaa32ce

Browse files
committed
Try to stabilize results of new tuplesort regression test.
It appears that a concurrent autovacuum/autoanalyze run can causechanges in the plans expected by this test. To prevent that, changethe tables it uses to be temp tables --- there's no need for themto be permanent, and this should save a few cycles too.Discussion:https://postgr.es/m/3244.1576160824@sss.pgh.pa.us
1 parent6ea364e commitbaa32ce

File tree

2 files changed

+4
-16
lines changed

2 files changed

+4
-16
lines changed

‎src/test/regress/expected/tuplesort.out

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,7 @@ SET max_parallel_workers = 0;
55
-- key aborts. One easy way to achieve that is to use uuids that all
66
-- have the same prefix, as abbreviated keys for uuids just use the
77
-- first sizeof(Datum) bytes.
8-
DROP TABLE IF EXISTS abbrev_abort_uuids;
9-
NOTICE: table "abbrev_abort_uuids" does not exist, skipping
10-
CREATE TABLE abbrev_abort_uuids (
8+
CREATE TEMP TABLE abbrev_abort_uuids (
119
id serial not null,
1210
abort_increasing uuid,
1311
abort_decreasing uuid,
@@ -596,7 +594,7 @@ ROLLBACK;
596594
----
597595
-- test tuplesort mark/restore
598596
---
599-
CREATE TABLE test_mark_restore(col1 int, col2 int, col12 int);
597+
CREATETEMPTABLE test_mark_restore(col1 int, col2 int, col12 int);
600598
-- need a few duplicates for mark/restore to matter
601599
INSERT INTO test_mark_restore(col1, col2, col12)
602600
SELECT a.i, b.i, a.i * b.i FROM generate_series(1, 500) a(i), generate_series(1, 5) b(i);
@@ -686,6 +684,3 @@ EXPLAIN (COSTS OFF) :qry;
686684
(10 rows)
687685

688686
COMMIT;
689-
-- cleanup
690-
DROP TABLE IF EXISTS abbrev_abort_uuids;
691-
DROP TABLE IF EXISTS test_mark_restore;

‎src/test/regress/sql/tuplesort.sql

Lines changed: 2 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,7 @@ SET max_parallel_workers = 0;
66
-- key aborts. One easy way to achieve that is to use uuids that all
77
-- have the same prefix, as abbreviated keys for uuids just use the
88
-- first sizeof(Datum) bytes.
9-
DROPTABLE IF EXISTS abbrev_abort_uuids;
10-
11-
CREATETABLEabbrev_abort_uuids (
9+
CREATE TEMP TABLE abbrev_abort_uuids (
1210
idserialnot null,
1311
abort_increasing uuid,
1412
abort_decreasing uuid,
@@ -266,7 +264,7 @@ ROLLBACK;
266264
-- test tuplesort mark/restore
267265
---
268266

269-
CREATETABLEtest_mark_restore(col1int, col2int, col12int);
267+
CREATETEMPTABLE test_mark_restore(col1int, col2int, col12int);
270268
-- need a few duplicates for mark/restore to matter
271269
INSERT INTO test_mark_restore(col1, col2, col12)
272270
SELECTa.i,b.i,a.i*b.iFROM generate_series(1,500) a(i), generate_series(1,5) b(i);
@@ -298,8 +296,3 @@ EXPLAIN (COSTS OFF) :qry;
298296
:qry;
299297

300298
COMMIT;
301-
302-
303-
-- cleanup
304-
DROPTABLE IF EXISTS abbrev_abort_uuids;
305-
DROPTABLE IF EXISTS test_mark_restore;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp