clickhouse-sink-connector
clickhouse-sink-connector copied to clipboard
Fix the getVersionColumnForReplacingMergeTree() to support replicated tables properly
-
In the current logic the getVersionColumnForReplacingMergeTree() returns only version_column from a replicated table definition (here
versionColumn = parameterArray[2].trim();
), but a is_deleted column migth be there too. -
It's unnecessary to have separate if clauses for replicated and nonreplicated tables, we can union them.
Please check DBMetadataTest
and add your new SQL that you are trying to fix.