我在kafka主题中有STRING格式的数据,现在当我创建Clickhouse表格时 像这样
DROP TABLE IF EXISTS conv_kafka;
CREATE TABLE conv_kafka (
id String,
attachments Array(String)
)
ENGINE = Kafka SETTINGS
kafka_broker_list = 'localhost:9092',
kafka_topic_list = 'test',
kafka_group_name = 'group_test',
kafka_format = 'CSV',
kafka_row_delimiter = '\n';
DROP TABLE IF EXISTS conv;
CREATE TABLE conv (
id String,
attachments Array(String)
)ENGINE = MergeTree() ORDER BY (id);
DROP TABLE IF EXISTS conv_mview;
CREATE MATERIALIZED VIEW conv_mview TO conv AS SELECT * FROM conv_kafka;
Clickhouse中没有数据。 PS:我尝试了JSONEachRow,TSV格式。 数据使用JSONEachRow传入,但所有值都为null。
背景信息: 我将数据从mongodb带入kafka主题,因此格式在STRING那里。创建“ DELIMITED”或“ JSON”格式的流也无法正常工作。在“ SHOW STREAMS”中,其显示格式为json或定界,但主题格式保持不变,即STRING