Hi,
On 11/27/23 1:23 PM, Zhijie Hou (Fujitsu) wrote:
On Monday, November 27, 2023 8:05 PM Drouvot, Bertrand
<bertranddrouvot...@gmail.com> wrote:
Did not look in details but it looks like there is more to do here as
this is failing (with v39_2):
"
postgres@primary: psql replication=database
psql (17devel)
Type "help" for help.
postgres=# CREATE_REPLICATION_SLOT test_logical20 LOGICAL pgoutput
FAILOVER;
ERROR: syntax error
I think the command you executed is of old syntax style, which was kept for
compatibility with older releases. And I think we can avoid supporting new
option for the old syntax as described in the original thread[1] of commit
0266e98. So, the "syntax error" is as expected IIUC.
The new style command is like:
CREATE_REPLICATION_SLOT test_logical20 LOGICAL pgoutput (FAILOVER);
[1]
https://www.postgresql.org/message-id/CA%2BTgmobAczXDRO_Gr2euo_TxgzaH1JxbNxvFx%3DHYvBinefNH8Q%40mail.gmail.com
Oh, I see, thanks for pointing out.
Well, not related to that thread but it seems weird to me that the backward
compatibility is done at the "option" level then.
I think it would make more sense to support all the options if the old
syntax is still supported.
For example, having
postgres=# CREATE_REPLICATION_SLOT test_logical2 LOGICAL pgoutput TWO_PHASE;
working fine but
CREATE_REPLICATION_SLOT test_logical3 LOGICAL pgoutput FAILOVER;
failing looks weird to me.
But that's probably out of this thread's context anyway.
Regards,
--
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com