【发布时间】:2021-03-31 02:34:04
【问题描述】:
我有一个 ClickHouse 服务器实例正在运行,并且我已通过客户端成功连接到它。我正在使用 Tabix.io 运行我的查询。我创建了一个数据库和一个名为“名称”的表。我想在该表中输入很多随机生成的名称。我知道运行多个这样的命令:
insert into names (id, first_name, last_name) values (1, 'Stephana', 'Bromell');
insert into names (id, first_name, last_name) values (2, 'Babita', 'Leroux');
insert into names (id, first_name, last_name) values (3, 'Pace', 'Christofides');
...
insert into names (id, first_name, last_name) values (999, 'Ralph', 'Jackson');
不受支持,因此它只是执行的第一个查询。换句话说,只有 Stephana Bromell 出现在“名称”表中。
用于插入大量数据的 ClickHouse 替代方案是什么?
【问题讨论】:
-
考虑使用Buffer Table Engine。查看相关答案 - stackoverflow.com/a/52437466/303298
-
这能回答你的问题吗? Multiple small inserts in clickhouse
-
@vladimir 谢谢!我肯定会在稍后阶段使用缓冲表。
标签: clickhouse