Avoid naming conflict between transactions.sql and namespace.sql.

Commits 681d9e462 et al added a test case in namespace.sql that
implicitly relied on there not being a table "public.abc".
However, the concurrently-run transactions.sql test creates precisely
such a table, so with the right timing you'd get a failure.
Creating a table named as generically as "abc" in a common schema
seems like bad practice, so fix this by changing the name of
transactions.sql's table.  (Compare 2cf8c7aa4.)

Marina Polyakova

Discussion: https://postgr.es/m/80d0201636665d82185942e7112257b4@postgrespro.ru
This commit is contained in:
Tom Lane 2023-05-19 10:57:46 -04:00
parent fc7dc728d1
commit 6f1cf2efbd
2 changed files with 18 additions and 18 deletions

View File

@ -571,10 +571,10 @@ drop function inverse(int);
-- performed in the aborted subtransaction
begin;
savepoint x;
create table abc (a int);
insert into abc values (5);
insert into abc values (10);
declare foo cursor for select * from abc;
create table trans_abc (a int);
insert into trans_abc values (5);
insert into trans_abc values (10);
declare foo cursor for select * from trans_abc;
fetch from foo;
a
---
@ -587,11 +587,11 @@ fetch from foo;
ERROR: cursor "foo" does not exist
commit;
begin;
create table abc (a int);
insert into abc values (5);
insert into abc values (10);
insert into abc values (15);
declare foo cursor for select * from abc;
create table trans_abc (a int);
insert into trans_abc values (5);
insert into trans_abc values (10);
insert into trans_abc values (15);
declare foo cursor for select * from trans_abc;
fetch from foo;
a
---

View File

@ -358,10 +358,10 @@ drop function inverse(int);
begin;
savepoint x;
create table abc (a int);
insert into abc values (5);
insert into abc values (10);
declare foo cursor for select * from abc;
create table trans_abc (a int);
insert into trans_abc values (5);
insert into trans_abc values (10);
declare foo cursor for select * from trans_abc;
fetch from foo;
rollback to x;
@ -371,11 +371,11 @@ commit;
begin;
create table abc (a int);
insert into abc values (5);
insert into abc values (10);
insert into abc values (15);
declare foo cursor for select * from abc;
create table trans_abc (a int);
insert into trans_abc values (5);
insert into trans_abc values (10);
insert into trans_abc values (15);
declare foo cursor for select * from trans_abc;
fetch from foo;