From b0422b215c100bb29c1071872012a1f3c6681058 Mon Sep 17 00:00:00 2001 From: Tom Lane Date: Thu, 12 Dec 2002 20:35:16 +0000 Subject: Preliminary code review for domain CHECK constraints patch: add documentation, make VALUE a non-reserved word again, use less invasive method of passing ConstraintTestValue into transformExpr, fix problems with nested constraint testing, do correct thing with NULL result from a constraint expression, remove memory leak. Domain checks still need much more work if we are going to allow ALTER DOMAIN, however. --- src/test/regress/expected/domain.out | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/test') diff --git a/src/test/regress/expected/domain.out b/src/test/regress/expected/domain.out index f91191bddb6..cbbb9023794 100644 --- a/src/test/regress/expected/domain.out +++ b/src/test/regress/expected/domain.out @@ -115,7 +115,7 @@ INSERT INTO nulltest DEFAULT VALUES; ERROR: Domain dnotnull does not allow NULL values INSERT INTO nulltest values ('a', 'b', 'c', 'd', 'c'); -- Good insert into nulltest values ('a', 'b', 'c', 'd', NULL); -ERROR: ExecEvalConstraintTest: Domain dcheck constraint $1 failed +ERROR: Domain dcheck does not allow NULL values insert into nulltest values ('a', 'b', 'c', 'd', 'a'); ERROR: ExecInsert: rejected due to CHECK constraint "nulltest_col5" on "nulltest" INSERT INTO nulltest values (NULL, 'b', 'c', 'd', 'd'); @@ -127,7 +127,7 @@ ERROR: ExecInsert: Fail to add null value in not null attribute col3 INSERT INTO nulltest values ('a', 'b', 'c', NULL, 'd'); -- Good -- Test copy COPY nulltest FROM stdin; --fail -ERROR: copy: line 1, ExecEvalConstraintTest: Domain dcheck constraint $1 failed +ERROR: copy: line 1, Domain dcheck does not allow NULL values lost synchronization with server, resetting connection SET autocommit TO 'on'; -- Last row is bad -- cgit v1.2.3