0

Need some help with pglogical replication. Following is my replication setup:

On the Publisher side, node created successfully. I applied row filtering on a column for some tables. Something like:

SELECT pglogical.replication_set_add_table(set_name:= 'default', relation := 'table_1', row_filter:= ' country=''USA'' ');

SELECT pglogical.replication_set_add_table(set_name:= 'default', relation := 'table_2', row_filter:= ' country=''USA'' ');

SELECT pglogical.replication_set_add_table(set_name:= 'default', relation := 'table_3', row_filter:= ' country=''USA'' ');

On the Subscriber side, node created successfully. When I create the subscription to the publisher, the pglogical.show_subscription_status() stays in initializing status for sometime and then changes to down I checked the subscriber DB logs and I see the following error:

LOG:  statement: COPY "public"."table_1"("id","column_1","column_2",...........,"some_column") FROM stdin
ERROR:  null value in column "some_column" violates not-null constraint

I check the Publisher and there are no NULL values in some_column in table_1. I also checked the specific row in table_1 which error'ed out and the some_column's value is 'f'. The some_column is a Boolean NOT NULL column.

Any suggestions on how to resolve this issue?

Thanks.

Anthony Sotolongo
  • 1,395
  • 2
  • 9
  • 17
P_Ar
  • 377
  • 2
  • 9
  • 25
  • 1
    take a look at this bug: https://github.com/2ndQuadrant/pglogical/issues/8 what is the version of pglogical you are using ? – mshabou Jan 26 '22 at 01:19
  • @mshabou -- I am using pglogical on an Aurora instance with Postgres 11.9 ..... How to check with pglogical version is installed? – P_Ar Jan 26 '22 at 03:49

0 Answers0