Re: Error message inconsistency - Mailing list pgsql-hackers

From Mahendra Singh Thalor
Subject Re: Error message inconsistency
Date
Msg-id CAKYtNAqRSkbV+scUerHu3vwaQHm1rhOPKth5GJcOUxT6ZmBf2Q@mail.gmail.com
Whole thread Raw
In response to Re: Error message inconsistency  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: Error message inconsistency  (MBeena Emerson <mbeena.emerson@gmail.com>)
Re: Error message inconsistency  (Amit Kapila <amit.kapila16@gmail.com>)
List pgsql-hackers
On Sat, 6 Jul 2019 at 09:53, Amit Kapila <amit.kapila16@gmail.com> wrote:
>
> On Mon, Jul 1, 2019 at 10:05 PM Alvaro Herrera <alvherre@2ndquadrant.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
Attachment

pgsql-hackers by date:

Previous
From: Tomas Vondra
Date:
Subject: Re: [Proposal] Global temporary tables
Next
From: Tomas Vondra
Date:
Subject: Re: Ltree syntax improvement