itinycheng / flink-connector-clickhouse

Flink SQL connector for ClickHouse. Support ClickHouseCatalog and read/write primary data, maps, arrays to clickhouse.
Apache License 2.0
346 stars 148 forks source link

[Bug]: UInt Type Not Supprot to Read Or Write #136

Open czy006 opened 2 weeks ago

czy006 commented 2 weeks ago

What happened?

UInt Type Not Supprot to Read Or Write on connector

Affects Versions

master

What are you seeing the problem on?

No response

How to reproduce

img_v3_02bq_29471db6-b13b-4022-ab7d-a0e95ab2000g

Clickhouse Create Table SQL

CREATE TABLE test.persona_wide_table
(

    `id` UInt64,
    `col1` String,
    `col2` String,
    `col3` String
)
ENGINE = MergeTree
ORDER BY id
SETTINGS index_granularity = 8192;

Flink SQL Create And Select SQL

CREATE TABLE test
(
    `id` DECIMAL,
    `col1` String,
    `col2` String,
    `col3` String
) WITH (
    'connector' = 'clickhouse',
    'url' = 'jdbc:ch://xxxx:8123?useSSL=false',
    'database-name' = 'test',
    'table-name' = 'persona_wide_table',
    'sink.batch-size' = '500',
    'sink.flush-interval' = '1000',
    'sink.max-retries' = '3'
);

ClickHouseDataType image

Relevant log output

No response

Anything else

Are you willing to submit a PR?

Code of Conduct

itinycheng commented 1 hour ago

Hi @czy006 : I'm working on data conversion logic for compatibility with clickhouse-jdbc 0.6. Can you assign this issue to me?