From: | MBeena Emerson <mbeena(dot)emerson(at)gmail(dot)com> |
---|---|
To: | Mahendra Singh Thalor <mahi6run(at)gmail(dot)com> |
Cc: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Fabrízio Mello <fabriziomello(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Error message inconsistency |
Date: | 2020-01-09 12:12:19 |
Message-ID: | CANPX-3XDFzuJkQgF2LeVhr8JVVe6vbTnH8NgP-sgZ2XOu2tG5A@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi Mahendra,
Thanks for the patch.
I am not sure but maybe the relation name should also be added to the
following test case?
create table t4 (id int);
insert into t4 values (1);
ALTER TABLE t4 ADD CONSTRAINT c1 CHECK (id > 10) NOT VALID; -- succeeds
ALTER TABLE t4 VALIDATE CONSTRAINT c1;
*ERROR: check constraint "c1" is violated by some row*
On Mon, 6 Jan 2020 at 18:31, Mahendra Singh Thalor <mahi6run(at)gmail(dot)com>
wrote:
> On Sat, 6 Jul 2019 at 09:53, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> >
> > On Mon, Jul 1, 2019 at 10:05 PM Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
> wrote:
> > >
> > > Do we have an actual patch here?
> > >
> >
> > We have a patch, but it needs some more work like finding similar
> > places and change all of them at the same time and then change the
> > tests to adapt the same.
> >
>
> Hi all,
> Based on above discussion, I tried to find out all the places where we
> need to change error for "not null constraint". As Amit Kapila pointed out
> 1 place, I changed the error and adding modified patch.
>
>
> *What does this patch? *
> Before this patch, to display error of "not-null constraint", we were not
> displaying relation name in some cases so attached patch is adding relation
> name with the "not-null constraint" error in 2 places. I didn't changed out
> files of test suite as we haven't finalized error messages.
>
> I verified Robert's point of for partition tables also. With the error, we
> are adding relation name of "child table" and i think, it is correct.
>
> Please review attached patch and let me know feedback.
>
> Thanks and Regards
> Mahendra Singh Thalor
> EnterpriseDB: http://www.enterprisedb.com
>
--
--
M Beena Emerson
From | Date | Subject | |
---|---|---|---|
Next Message | Christoph Berg | 2020-01-09 12:48:55 | Re: Allow 'sslkey' and 'sslcert' in postgres_fdw user mappings |
Previous Message | Sergei Kornilov | 2020-01-09 12:01:44 | Re: [HACKERS] Block level parallel vacuum |