问题描述
我有100亿条详细数据查询的需求。 Clickhouse
中存储了 100 亿条数据。我需要分开数据库和表吗?
我使用的表引擎是 ReplicatedReplacingMergeTree
查询语句如下:
select * from table_a where name = 'akkj';
select * from table_b where name = 'bttc';
解决方法
不,您可以在单个表中存储任意数量的行。
我的作品:
SELECT count()
FROM fact_event_shard
┌───────count()─┐
│ 1415809324034 │
└───────────────┘
select * from table_a where name = 'akkj'; select * from table_b where name = 'bttc';
非常糟糕的主意。 Clickhouse 不喜欢这样的查询。您应该使用 Cassandra,而不是 Clichkouse。