On 06.02.25 14:03, vignesh C wrote:
> One suggestion: for the option where the user specifies
> publish_generated_columns as virtual (as shown below), could we change
> the error indicating that virtual generated columns are not currently
> supported?
> CREATE PUBLICATION pub1 FOR TABLE t1 WITH (publish_generated_columns = virtual);
>
> Also, could we add a XXX comment in either decode.c, pgoutput.c, or
> publicationcmds.c outlining what would be needed to support the
> replication of virtual generated columns? Specifically, it would be
> helpful if we could include how to retrieve virtual generated column
> data during decoding. This would serve as a reference for anyone
> working on enabling logical replication of virtual generated columns
> in the future.
I think adding support for virtual generated columns in logical
replication would require a lot more work than filling in the handful of
places that we know about. (Otherwise, we'd already have done it now.)
So I'd rather not give potentially misleading or incomplete advice.