From: | Shubham Khanna <khannashubham1197(at)gmail(dot)com> |
---|---|
To: | vignesh C <vignesh21(at)gmail(dot)com> |
Cc: | Peter Smith <smithpb2250(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Improve the error message for logical replication of regular column to generated column. |
Date: | 2024-11-18 11:41:11 |
Message-ID: | CAHv8RjLwoL6Qr-hw0D2OJ45dxyZdJDECCfe8MhBnVVz0YsJo1Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Mon, Nov 18, 2024 at 4:11 PM vignesh C <vignesh21(at)gmail(dot)com> wrote:
>
> On Mon, 18 Nov 2024 at 15:47, Shubham Khanna
> <khannashubham1197(at)gmail(dot)com> wrote:
> >
> > On Fri, Nov 15, 2024 at 7:07 PM vignesh C <vignesh21(at)gmail(dot)com> wrote:
> >
> > I have fixed the given comments. The attached Patch contains the
> > required changes.
>
> Couple of minor comments:
> 1) Since the previous error is going to exit, this pfree is not required:
> + else
> + ereport(ERROR,
> +
> (errcode(ERRCODE_OBJECT_NOT_IN_PREREQUISITE_STATE),
> + errmsg_plural("cannot
> replicate to target relation \"%s.%s\" generated column: %s",
> +
> "cannot replicate to target relation \"%s.%s\" generated columns: %s",
> + attcnt,
> +
> remoterel->nspname,
> +
> remoterel->relname,
> +
> attsbuf.data)));
> +
> + pfree(attsbuf.data);
>
>
> 2) "You can add single-line comments such as 'Report missing columns'
> and 'Report replicating to generated columns.'"
> + logicalrep_report_missing_and_gen_attrs(remoterel,
> generatedattrs,
> +
> false);
> + logicalrep_report_missing_and_gen_attrs(remoterel, missingatts,
> +
> true);
>
I have fixed the given comments. The attached Patch contains the
required changes.
Thanks and regards,
Shubham Khanna.
Attachment | Content-Type | Size |
---|---|---|
v4-0001-Error-message-improvement.patch | application/octet-stream | 8.4 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Rafia Sabih | 2024-11-18 11:49:23 | Re: Forbid to DROP temp tables of other sessions |
Previous Message | Andrey M. Borodin | 2024-11-18 11:34:39 | Re: Using read_stream in index vacuum |