Skip to content

Commit 257d815

Browse files
committed
Fix unstable regression test results.
Commit 2ac3ef7 added a query with an underdetermined output row order; it has failed multiple times in the buildfarm since then. Add an ORDER BY to fix. Also, don't rely on a DROP CASCADE to drop in a well-determined order; that hasn't failed yet but I don't trust it much, and we're not saving any typing by using CASCADE anyway.
1 parent 80a7298 commit 257d815

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

src/test/regress/expected/insert.out

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,8 @@ from pg_attribute
314314
where attname = 'a'
315315
and (attrelid = 'p'::regclass
316316
or attrelid = 'p1'::regclass
317-
or attrelid = 'p11'::regclass);
317+
or attrelid = 'p11'::regclass)
318+
order by attrelid::regclass::text;
318319
attrelid | attname | attnum
319320
----------+---------+--------
320321
p | a | 1
@@ -333,7 +334,4 @@ select tableoid::regclass, * from p;
333334
(1 row)
334335

335336
-- cleanup
336-
drop table p cascade;
337-
NOTICE: drop cascades to 2 other objects
338-
DETAIL: drop cascades to table p1
339-
drop cascades to table p11
337+
drop table p, p1, p11;

src/test/regress/sql/insert.sql

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,8 @@ from pg_attribute
185185
where attname = 'a'
186186
and (attrelid = 'p'::regclass
187187
or attrelid = 'p1'::regclass
188-
or attrelid = 'p11'::regclass);
188+
or attrelid = 'p11'::regclass)
189+
order by attrelid::regclass::text;
189190

190191
alter table p1 attach partition p11 for values from (2) to (5);
191192
alter table p attach partition p1 for values from (1, 2) to (1, 10);
@@ -195,4 +196,4 @@ insert into p values (1, 2);
195196
select tableoid::regclass, * from p;
196197

197198
-- cleanup
198-
drop table p cascade;
199+
drop table p, p1, p11;

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy