Skip to content

Commit ab1a78a

Browse files
michaelpqavamingli
authored andcommitted
Fix instability in regression test for Parallel Hash Full Join
As reported by buildfarm member conchuela, one of the regression tests added by 558c9d7 is having some ordering issues. This commit adds an ORDER BY clause to make the output more stable for the problematic query. Fix suggested by Tom Lane. The plan of the query updated still uses a parallel hash full join. Author: Melanie Plageman Discussion: https://postgr.es/m/623596.1684541098@sss.pgh.pa.us
1 parent 8556f54 commit ab1a78a

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

src/test/regress/expected/join_hash.out

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1047,7 +1047,8 @@ INSERT INTO hjtest_matchbits_t2 VALUES (2);
10471047
-- Update should create a HOT tuple. If this status bit isn't cleared, we won't
10481048
-- correctly emit the NULL-extended unmatching tuple in full hash join.
10491049
UPDATE hjtest_matchbits_t2 set id = 2;
1050-
SELECT * FROM hjtest_matchbits_t1 t1 FULL JOIN hjtest_matchbits_t2 t2 ON t1.id = t2.id;
1050+
SELECT * FROM hjtest_matchbits_t1 t1 FULL JOIN hjtest_matchbits_t2 t2 ON t1.id = t2.id
1051+
ORDER BY t1.id;
10511052
id | id
10521053
----+----
10531054
1 |

src/test/regress/sql/join_hash.sql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -555,7 +555,8 @@ INSERT INTO hjtest_matchbits_t2 VALUES (2);
555555
-- Update should create a HOT tuple. If this status bit isn't cleared, we won't
556556
-- correctly emit the NULL-extended unmatching tuple in full hash join.
557557
UPDATE hjtest_matchbits_t2 set id = 2;
558-
SELECT * FROM hjtest_matchbits_t1 t1 FULL JOIN hjtest_matchbits_t2 t2 ON t1.id = t2.id;
558+
SELECT * FROM hjtest_matchbits_t1 t1 FULL JOIN hjtest_matchbits_t2 t2 ON t1.id = t2.id
559+
ORDER BY t1.id;
559560
-- Test serial full hash join.
560561
-- Resetting parallel_setup_cost should force a serial plan.
561562
-- Just to be safe, however, set enable_parallel_hash to off, as parallel full

0 commit comments

Comments
 (0)