From: | Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com> |
---|---|
To: | vignesh C <vignesh21(at)gmail(dot)com> |
Cc: | Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: CREATE COLLATION - check for duplicate options and error out if found one |
Date: | 2021-07-15 19:34:38 |
Message-ID: | CAEZATCXfQU84HOtNuLpRXUJe_GPcYRPNj5MrZk=YuzAT=f5b0w@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, 31 May 2021 at 15:10, vignesh C <vignesh21(at)gmail(dot)com> wrote:
>
> On Sat, May 29, 2021 at 9:20 PM Bharath Rupireddy
> <bharath(dot)rupireddyforpostgres(at)gmail(dot)com> wrote:
> >
> > Thanks. PSA v3 patch.
>
> Thanks for the updated patch, the changes look good to me.
>
Hi,
Having pushed [1], I started looking at this, and I think it's mostly
in good shape.
Since we're improving the CREATE COLLATION errors, I think it's also
worth splitting out the error for LOCALE + LC_COLLATE/LC_CTYPE from
the error for FROM + any other option.
In the case of LOCALE + LC_COLLATE/LC_CTYPE, there is an identical
error in CREATE DATABASE, so we should use the same error message and
detail text here.
Then logically, FROM + any other option should have an error of the
same general form.
And finally, it then makes sense to make the other errors follow the
same pattern (with the "specified more than once" text in the detail),
which is also where we ended up in the discussion over in [1].
So, attached is what I propose.
Regards,
Dean
Attachment | Content-Type | Size |
---|---|---|
v4-check-CREATE-COLLATION-options.patch | text/x-patch | 8.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Daniel Gustafsson | 2021-07-15 19:46:36 | Re: Avoid repeated PQfnumber() in pg_dump |
Previous Message | Zhihong Yu | 2021-07-15 19:28:13 | Re: Removing unneeded self joins |