Fix doc bug in logical replication.

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Fix doc bug in logical replication.

Robert Treat-3
Howdy folks,

I noticed that the docs currently state "A different order of columns
in the target table is allowed, but the column types have to match."
This is untrue, as you can replicate between any two data types as
long as the data can be coerced into the right format on the
subscriber. Attached is a patch that attempts to clarify this, and
provides some additional wordsmithing of that section. Patch is
against head but the nature of the patch would apply to the docs for
11 and 10, which both have the incorrect information as well, even if
the patch itself does not.


Robert Treat
https://xzilla.net

logical_replication_type_mismatch.patch (1K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Fix doc bug in logical replication.

Euler Taveira
Em seg, 8 de abr de 2019 às 19:38, Robert Treat <[hidden email]> escreveu:

>
> I noticed that the docs currently state "A different order of columns
> in the target table is allowed, but the column types have to match."
> This is untrue, as you can replicate between any two data types as
> long as the data can be coerced into the right format on the
> subscriber. Attached is a patch that attempts to clarify this, and
> provides some additional wordsmithing of that section. Patch is
> against head but the nature of the patch would apply to the docs for
> 11 and 10, which both have the incorrect information as well, even if
> the patch itself does not.
>
I would say it is inaccurate because the actual instruction works. I
agree that your words are an improvement but it lacks a comment on the
slot_[store|modify]_cstrings.


--
   Euler Taveira                                   Timbira -
http://www.timbira.com.br/
   PostgreSQL: Consultoria, Desenvolvimento, Suporte 24x7 e Treinamento


Reply | Threaded
Open this post in threaded view
|

Re: Fix doc bug in logical replication.

Robert Treat-3
On Mon, Apr 8, 2019 at 7:19 PM Euler Taveira <[hidden email]> wrote:

>
> Em seg, 8 de abr de 2019 às 19:38, Robert Treat <[hidden email]> escreveu:
> >
> > I noticed that the docs currently state "A different order of columns
> > in the target table is allowed, but the column types have to match."
> > This is untrue, as you can replicate between any two data types as
> > long as the data can be coerced into the right format on the
> > subscriber. Attached is a patch that attempts to clarify this, and
> > provides some additional wordsmithing of that section. Patch is
> > against head but the nature of the patch would apply to the docs for
> > 11 and 10, which both have the incorrect information as well, even if
> > the patch itself does not.
> >
> I would say it is inaccurate because the actual instruction works. I
> agree that your words are an improvement but it lacks a comment on the
> slot_[store|modify]_cstrings.
>

It is clear to me that the docs are wrong, but I don't see anything
inherently incorrect about the code itself. Do you have suggestions
for how you would like to see the code comments improved?


Robert Treat
https://xzilla.net