2019-04-03 19:38:20 +02:00
|
|
|
# Verify that cloning a foreign key constraint to a partition ensures
|
|
|
|
# that referenced values exist, even if they're being concurrently
|
|
|
|
# deleted.
|
|
|
|
setup {
|
|
|
|
drop table if exists ppk, pfk, pfk1;
|
|
|
|
create table ppk (a int primary key) partition by list (a);
|
|
|
|
create table ppk1 partition of ppk for values in (1);
|
|
|
|
insert into ppk values (1);
|
|
|
|
create table pfk (a int references ppk) partition by list (a);
|
|
|
|
create table pfk1 (a int not null);
|
|
|
|
insert into pfk1 values (1);
|
|
|
|
}
|
|
|
|
|
Allow non-quoted identifiers as isolation test session/step names.
For no obvious reason, isolationtester has always insisted that
session and step names be written with double quotes. This is
fairly tedious and does little for test readability, especially
since the names that people actually choose almost always look
like normal identifiers. Hence, let's tweak the lexer to allow
SQL-like identifiers not only double-quoted strings.
(They're SQL-like, not exactly SQL, because I didn't add any
case-folding logic. Also there's no provision for U&"..." names,
not that anyone's likely to care.)
There is one incompatibility introduced by this change: if you write
"foo""bar" with no space, that used to be taken as two identifiers,
but now it's just one identifier with an embedded quote mark.
I converted all the src/test/isolation/ specfiles to remove
unnecessary double quotes, but stopped there because my
eyes were glazing over already.
Like 741d7f104, back-patch to all supported branches, so that this
isn't a stumbling block for back-patching isolation test changes.
Discussion: https://postgr.es/m/759113.1623861959@sss.pgh.pa.us
2021-06-24 00:41:39 +02:00
|
|
|
session s1
|
|
|
|
step s1b { begin; }
|
|
|
|
step s1d { delete from ppk1 where a = 1; }
|
|
|
|
step s1c { commit; }
|
2019-04-03 19:38:20 +02:00
|
|
|
|
Allow non-quoted identifiers as isolation test session/step names.
For no obvious reason, isolationtester has always insisted that
session and step names be written with double quotes. This is
fairly tedious and does little for test readability, especially
since the names that people actually choose almost always look
like normal identifiers. Hence, let's tweak the lexer to allow
SQL-like identifiers not only double-quoted strings.
(They're SQL-like, not exactly SQL, because I didn't add any
case-folding logic. Also there's no provision for U&"..." names,
not that anyone's likely to care.)
There is one incompatibility introduced by this change: if you write
"foo""bar" with no space, that used to be taken as two identifiers,
but now it's just one identifier with an embedded quote mark.
I converted all the src/test/isolation/ specfiles to remove
unnecessary double quotes, but stopped there because my
eyes were glazing over already.
Like 741d7f104, back-patch to all supported branches, so that this
isn't a stumbling block for back-patching isolation test changes.
Discussion: https://postgr.es/m/759113.1623861959@sss.pgh.pa.us
2021-06-24 00:41:39 +02:00
|
|
|
session s2
|
|
|
|
step s2b { begin; }
|
|
|
|
step s2a { alter table pfk attach partition pfk1 for values in (1); }
|
|
|
|
step s2c { commit; }
|
2019-04-03 19:38:20 +02:00
|
|
|
|
|
|
|
teardown { drop table ppk, pfk, pfk1; }
|
|
|
|
|
Allow non-quoted identifiers as isolation test session/step names.
For no obvious reason, isolationtester has always insisted that
session and step names be written with double quotes. This is
fairly tedious and does little for test readability, especially
since the names that people actually choose almost always look
like normal identifiers. Hence, let's tweak the lexer to allow
SQL-like identifiers not only double-quoted strings.
(They're SQL-like, not exactly SQL, because I didn't add any
case-folding logic. Also there's no provision for U&"..." names,
not that anyone's likely to care.)
There is one incompatibility introduced by this change: if you write
"foo""bar" with no space, that used to be taken as two identifiers,
but now it's just one identifier with an embedded quote mark.
I converted all the src/test/isolation/ specfiles to remove
unnecessary double quotes, but stopped there because my
eyes were glazing over already.
Like 741d7f104, back-patch to all supported branches, so that this
isn't a stumbling block for back-patching isolation test changes.
Discussion: https://postgr.es/m/759113.1623861959@sss.pgh.pa.us
2021-06-24 00:41:39 +02:00
|
|
|
permutation s1b s1d s1c s2b s2a s2c
|
|
|
|
permutation s1b s1d s2b s1c s2a s2c
|
|
|
|
permutation s1b s1d s2b s2a s1c s2c
|
|
|
|
#permutation s1b s1d s2b s2a s2c s1c
|
|
|
|
permutation s1b s2b s1d s1c s2a s2c
|
|
|
|
permutation s1b s2b s1d s2a s1c s2c
|
|
|
|
#permutation s1b s2b s1d s2a s2c s1c
|
|
|
|
#permutation s1b s2b s2a s1d s1c s2c
|
|
|
|
permutation s1b s2b s2a s1d s2c s1c
|
|
|
|
permutation s1b s2b s2a s2c s1d s1c
|
|
|
|
permutation s2b s1b s1d s1c s2a s2c
|
|
|
|
permutation s2b s1b s1d s2a s1c s2c
|
|
|
|
#permutation s2b s1b s1d s2a s2c s1c
|
|
|
|
#permutation s2b s1b s2a s1d s1c s2c
|
|
|
|
permutation s2b s1b s2a s1d s2c s1c
|
|
|
|
permutation s2b s1b s2a s2c s1d s1c
|
|
|
|
#permutation s2b s2a s1b s1d s1c s2c
|
|
|
|
permutation s2b s2a s1b s1d s2c s1c
|
|
|
|
permutation s2b s2a s1b s2c s1d s1c
|
|
|
|
permutation s2b s2a s2c s1b s1d s1c
|