0

Wonder if there is a way to add more details (like the column name, database) to logical replication errors in case of missing columns. I got general log entries like this:

2021-09-16 14:47:37.149 CDT [32910] ERROR:  logical replication target relation "public.users" is missing some replicated columns

I could not find anything related in the documentation. I am trying to detect these kinds of errors to trigger an alert or something like that. The only idea that I have is to watch the logs for entries like the above one. Any idea will be welcome!

0

That is obvious: the target table is missing some columns (or they have the wrong name).

The target table must have all the columns from the source table, although the definition of these columns need not to be identical.

This behavior has been improved in PostgreSQL v15.

3
  • Yeah, I know that. The problem is that the error messages do not show the column name so I was wondering if there is a way to show more information in the log like the missing column Sep 20 '21 at 0:38
  • No, you cannot get more log information - but if that is possible, it would be a nice improvement. Perhaps you could come up with a patch. Sep 20 '21 at 2:38
  • 1
    Bummer - thanks for your answer @LaurenzAlbe. Looks like there is already a discussion about that improvement: here Sep 20 '21 at 15:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.