aboutsummaryrefslogtreecommitdiff
path: root/src/test/regress/expected/constraints.out
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/regress/expected/constraints.out')
-rw-r--r--src/test/regress/expected/constraints.out10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/test/regress/expected/constraints.out b/src/test/regress/expected/constraints.out
index d9d8408e869..483681ef2c6 100644
--- a/src/test/regress/expected/constraints.out
+++ b/src/test/regress/expected/constraints.out
@@ -1010,13 +1010,21 @@ ERROR: constraint "cnn_parent_pkey" of relation "cnn_parent" does not exist
create table cnn2_parted(a int primary key) partition by list (a);
create table cnn2_part1(a int);
alter table cnn2_parted attach partition cnn2_part1 for values in (1);
-ERROR: primary key column "a" is not marked NOT NULL
+insert into cnn2_part1 values (null);
+ERROR: null value in column "a" of relation "cnn2_part1" violates not-null constraint
+DETAIL: Failing row contains (null).
drop table cnn2_parted, cnn2_part1;
create table cnn2_parted(a int not null) partition by list (a);
create table cnn2_part1(a int primary key);
alter table cnn2_parted attach partition cnn2_part1 for values in (1);
ERROR: column "a" in child table must be marked NOT NULL
drop table cnn2_parted, cnn2_part1;
+create table cnn2_parted(a int) partition by list (a);
+create table cnn_part1 partition of cnn2_parted for values in (1, null);
+insert into cnn_part1 values (null);
+alter table cnn2_parted add primary key (a);
+ERROR: column "a" of relation "cnn_part1" contains null values
+drop table cnn2_parted;
-- columns in regular and LIKE inheritance should be marked not-nullable
-- for primary keys, even if those are deferred
CREATE TABLE notnull_tbl4 (a INTEGER PRIMARY KEY INITIALLY DEFERRED);