From: | amul sul <sul_amul(at)yahoo(dot)co(dot)in> |
---|---|
To: | Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Passing initially_valid values instead of !skip_validation to StoreRelCheck() in AddRelationNewConstraints() |
Date: | 2015-12-03 11:44:49 |
Message-ID: | 1238779931.11913728.1449143089410.JavaMail.yahoo@mail.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi Amit,
Thanks for prompt response.
>On Thursday, 3 December 2015 4:36 PM, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp> wrote:
>Especially from a readability standpoint, I think using skip_validation may be more apt.
>Why - the corresponding parameter of StoreRelCheck() dictates what's stored in pg_constraint.convalidated.
Why not? won't initially_valid flag serve same purpose ?
> So, if skip_validation is 'true' because user specified the constraint NOT VALID,
> StoreRelCheck() will store the constraint with convalidated as 'false'
I guess thats was added before initially_valid flag. As I said, in normal case gram.y take care of skip_validation & initially_valid values, if one is 'true' other will be 'false'.
>The user will have to separately validate the constraint by issuing a ALTER TABLE VALIDATE CONSTRAINT
>command at a time of their choosing.
This could be time consuming operation for big table, If I am pretty much sure that my constraint will be valid, simply I could set both flag(initially_valid & skip_validation) to true.
Regards,
Amul Sul
From | Date | Subject | |
---|---|---|---|
Next Message | Marko Tiikkaja | 2015-12-03 11:56:59 | Re: Passing initially_valid values instead of !skip_validation to StoreRelCheck() in AddRelationNewConstraints() |
Previous Message | Pavel Raiskup | 2015-12-03 11:39:48 | Re: broken tests |