From 61d81bd28dbec65a6b144e0cd3d0bfe25913c3ac Mon Sep 17 00:00:00 2001 From: Alvaro Herrera Date: Mon, 5 Dec 2011 15:10:18 -0300 Subject: Allow CHECK constraints to be declared ONLY This makes them enforceable only on the parent table, not on children tables. This is useful in various situations, per discussion involving people bitten by the restrictive behavior introduced in 8.4. Message-Id: 8762mp93iw.fsf@comcast.net CAFaPBrSMMpubkGf4zcRL_YL-AERUbYF_-ZNNYfb3CVwwEqc9TQ@mail.gmail.com Authors: Nikhil Sontakke, Alex Hunsaker Reviewed by Robert Haas and myself --- src/backend/utils/cache/relcache.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/backend/utils/cache') diff --git a/src/backend/utils/cache/relcache.c b/src/backend/utils/cache/relcache.c index 603e4c1b621..f9ad75e7f89 100644 --- a/src/backend/utils/cache/relcache.c +++ b/src/backend/utils/cache/relcache.c @@ -3261,6 +3261,7 @@ CheckConstraintFetch(Relation relation) RelationGetRelationName(relation)); check[found].ccvalid = conform->convalidated; + check[found].cconly = conform->conisonly; check[found].ccname = MemoryContextStrdup(CacheMemoryContext, NameStr(conform->conname)); -- cgit v1.2.3