Re: Dropped and generated columns might cause wrong data on subs when REPLICA IDENTITY FULL

Önder Kalacı <onderkalaci@gmail.com>

From: Önder Kalacı <onderkalaci@gmail.com>
To: "shiy.fnst@fujitsu.com" <shiy.fnst@fujitsu.com>
Cc: Amit Kapila <amit.kapila16@gmail.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2023-03-22T06:53:04Z
Lists: pgsql-hackers

Attachments

Hi Shi Yu,


>
> Is there any reasons why we drop column here? Dropped column case has been
> tested on table dropped_cols. The generated column problem can be detected
> without dropping columns on my machine.
>

We don't really need to, if you check the first patch, we don't have DROP
for generated case. I mostly
wanted to make the test a little more interesting, but it also seems to be
a little confusing.

Now attaching v2 where we do not drop the columns. I don't have strong
preference on
which patch to proceed with, mostly wanted to attach this version to
progress faster (in case
you/Amit considers this one better).

Thanks,
Onder

Commits

  1. Ignore generated columns during apply of update/delete.

  2. Ignore dropped columns during apply of update/delete.