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

Commit396676b

Browse files
committed
Enforce non-parallel plan when calling current_schema() in newly-added test
current_schema() gets called in the recently-added regression test fromc5660e0, and can be used in a parallel context, causing its call to failwhen creating a temporary schema.Per buildfarm members crake and lapwing.Discussion:https://postgr.es/m/20190118005949.GD1883@paquier.xyz
1 parent251f574 commit396676b

File tree

2 files changed

+8
-2
lines changed

2 files changed

+8
-2
lines changed

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

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -360,8 +360,11 @@ prepare transaction 'twophase_tab';
360360
ERROR: cannot PREPARE a transaction that has operated on temporary tables
361361
-- Corner case: current_schema may create a temporary schema if namespace
362362
-- creation is pending, so check after that. First reset the connection
363-
-- to remove the temporary namespace.
363+
-- to remove the temporary namespace, and make sure that non-parallel plans
364+
-- are used.
364365
\c -
366+
SET max_parallel_workers = 0;
367+
SET max_parallel_workers_per_gather = 0;
365368
SET search_path TO 'pg_temp';
366369
BEGIN;
367370
SELECT current_schema() ~ 'pg_temp' AS is_temp_schema;

‎src/test/regress/sql/temp.sql

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -274,8 +274,11 @@ prepare transaction 'twophase_tab';
274274

275275
-- Corner case: current_schema may create a temporary schema if namespace
276276
-- creation is pending, so check after that. First reset the connection
277-
-- to remove the temporary namespace.
277+
-- to remove the temporary namespace, and make sure that non-parallel plans
278+
-- are used.
278279
\c-
280+
SET max_parallel_workers=0;
281+
SET max_parallel_workers_per_gather=0;
279282
SET search_path TO'pg_temp';
280283
BEGIN;
281284
SELECT current_schema() ~'pg_temp'AS is_temp_schema;

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp