<@U04S8PLJWMT> we keep getting this error message ...
# ask-ai
h
@kapa.ai we keep getting this error message using the latest clickhouse connector. please advise
Copy code
Expected AirbyteType: StringType Actual protobuf ValueCase: BIG_DECIMAL This error indicates that the source connector is using the wrong protobuf setter method. The source must use the protobuf setter that corresponds to the declared schema type. Please fix the source connector to use the correct protobuf setter method for this column.
k
Based on the knowledge sources provided, I can see that your error is related to a data type mismatch in the ClickHouse connector. The error message indicates that the source connector is sending a
BIG_DECIMAL
value when the schema expects a
StringType
. This appears to be similar to issues documented in the knowledge sources. Specifically, there's a related issue about [CDC replication from PostgreSQL to ClickHouse with timestamp conversion problems](https://github.com/airbytehq/airbyte/issues/45451), and another about [NUMERIC column values being replicated as NULL](https://github.com/airbytehq/airbyte/issues/21276). The error suggests that: 1. The source connector is declaring a column as
StringType
in its schema
2. But it's actually sending
BIG_DECIMAL
(numeric) data via protobuf
To resolve this issue, I recommend: 1. Check your source connector version - Ensure you're using the latest version of your source connector, as this type of issue is typically fixed in connector updates. 2. Verify the data types - Check the actual data types of the columns in your source database, particularly for numeric/decimal columns that might be causing this mismatch. 3. Report the issue - Since the error message explicitly states "Please fix the source connector to use the correct protobuf setter method," this appears to be a bug in your source connector. You should report this as an issue on the [Airbyte GitHub repository](https://github.com/airbytehq/airbyte/issues), including: - Your source connector name and version - Your ClickHouse destination connector version - The specific column(s) causing the error - The data type of those columns in your source database 4. Temporary workaround - If possible, you might try excluding the problematic columns from your sync temporarily while waiting for a fix. Could you share which source connector you're using (e.g., PostgreSQL, MySQL, etc.) and its version? This would help provide more specific guidance.
h
@kapa.ai we are using mysql source connector latest version and and the column in the source table is actually varchar. this is a sample of the data in the column as varchar 202401127
k
A message from kapa.ai
Thank you for the clarification. This is very helpful information. The issue is now clearer - you have a VARCHAR column in MySQL containing numeric-looking data (like "202401127"), but there's a mismatch in how it's being processed. Based on the knowledge sources, this appears to be a data type mapping issue between the MySQL source connector and ClickHouse destination. Here's what's likely happening: The Problem: The MySQL source connector is correctly identifying the column as VARCHAR/string type, but somewhere in the data pipeline, the value is being converted to a
BIG_DECIMAL
(numeric type) instead of remaining as a string. This could be because: 1. The data looks numeric (all digits), which might trigger automatic type conversion 2. There's a mismatch in how the ClickHouse destination is interpreting the schema Recommended Solutions: 1. Check the Airbyte catalog/schema - In your connection settings, verify how Airbyte is detecting this column. According to the [forum discussion about data types](https://discuss.airbyte.io/t/3266), you can check the replication tab to see what data type Airbyte is reading for this column. 2. Review the sync logs - Look for lines similar to this pattern from the logs:
Copy code
Table <table_name> column <column_name> (type varchar[X]) -> JsonSchemaType({type=string})
This will confirm if the source connector is correctly identifying it as a string. 3. Update to the latest connector versions - Ensure you're using: - The latest MySQL source connector version - The latest ClickHouse destination connector version 4. Check ClickHouse type mapping - According to the [ClickHouse destination documentation](https://docs.airbyte.com/integrations/destinations/clickhouse), strings should be mapped to ClickHouse's
String
type. The issue might be in how the destination is handling the conversion. 5. Report as a bug - Since this appears to be a protobuf serialization issue where the source is using the wrong setter method, you should report this on the [Airbyte GitHub repository](https://github.com/airbytehq/airbyte/issues) with: - MySQL source connector version - ClickHouse destination connector version - The exact column definition from MySQL (
SHOW CREATE TABLE
output) - Sample data from the column - Full sync logs showing the error Could you share your sync logs and confirm which specific version of the MySQL source connector you're using? This would help identify if this is a known issue or needs to be reported.
h
@kapa.ai we are currently using mysql source connector version 3.51.0. I think the issue is the clickhouse destination connector. if we use clickhouse destination connector version 2.1.2, everythingf works fine. this issue only happens if we use the latest clickhouse destination connector version 2.1.7
k
A message from kapa.ai
Thank you for that crucial information! This narrows down the issue significantly. You've identified that the problem is specifically with ClickHouse destination connector version 2.1.7, while version 2.1.2 works fine with the same MySQL source connector (3.51.0). Looking at the [ClickHouse destination changelog](https://docs.airbyte.com/integrations/destinations/clickhouse#changelog), I can see what changed between these versions: Version 2.1.7 (2025-10-21): - [PR #67153](https://github.com/airbytehq/airbyte/pull/67153) - "Implement new proto schema implementation" This is very likely the root cause of your issue! The "new proto schema implementation" in version 2.1.7 appears to have introduced a regression in how VARCHAR/string columns containing numeric data are being handled via protobuf. Recommended Actions: 1. Immediate workaround: Continue using ClickHouse destination connector version 2.1.2 until this is resolved. This is a perfectly valid approach since you've confirmed it works correctly. 2. Report the regression: Please report this as a bug on the [Airbyte GitHub repository](https://github.com/airbytehq/airbyte/issues) with these details: - Working version: ClickHouse destination 2.1.2 - Broken version: ClickHouse destination 2.1.7 - Source: MySQL 3.51.0 - Column type: VARCHAR containing numeric data (e.g., "202401127") - Error: "Expected AirbyteType: StringType Actual protobuf ValueCase: BIG_DECIMAL" - Reference: PR #67153 (new proto schema implementation) 3. Monitor for fixes: Watch for subsequent ClickHouse destination connector releases that might fix this regression. The changelog shows active development, so a fix should come relatively quickly once reported. Since this is a clear regression introduced in a specific version, the Airbyte team will likely prioritize fixing it. In the meantime, staying on version 2.1.2 is the safest approach for your production workloads.