跳转到主内容
跳转到主内容

system.merges

在 ClickHouse Cloud 中进行查询

该系统表中的数据保存在 ClickHouse Cloud 中每个节点的本地。因此,如需获得所有数据的完整视图,需要使用 clusterAllReplicas 函数。更多详情请参阅此处

描述

包含关于 MergeTree 引擎家族表当前正在执行的合并 (merge) 和 part mutation 的信息。

  • database (String) — 该表所在数据库的名称。
  • table (String) — 表名。
  • elapsed (Float64) — 自合并开始以来经过的时间 (以秒为单位) 。
  • progress (Float64) — 已完成工作的比例,范围为 0 到 1。
  • num_parts (UInt64) — 待合并的 parts 数量。
  • source_part_names (Array(String)) — 源 parts 名称列表。
  • result_part_name (String) — 合并后生成的 part 名称。
  • source_part_paths (Array(String)) — 每个源 part 的路径列表。
  • result_part_path (String) — 合并后生成的 part 路径。
  • partition_id (String) — 发生合并的分区标识符。
  • partition (String) — 分区名称。
  • is_mutation (UInt8) — 如果此过程是 part mutation,则为 1。
  • total_size_bytes_compressed (UInt64) — 已合并块中压缩数据的总大小。
  • total_size_bytes_uncompressed (UInt64) — 已合并块中未压缩数据的总大小。
  • total_size_marks (UInt64) — 已合并 parts 中的 marks 总数。
  • bytes_read_uncompressed (UInt64) — 读取的未压缩字节数。
  • rows_read (UInt64) — 读取的行数。
  • bytes_written_uncompressed (UInt64) — 写入的未压缩字节数。
  • rows_written (UInt64) — 写入的行数。
  • columns_written (UInt64) — 写入的列数 (适用于 Vertical merge algorithm) 。
  • memory_usage (UInt64) — 合并过程的内存消耗。
  • thread_id (UInt64) — 合并过程的线程 ID。
  • merge_type (String) — 当前合并的类型。如果是 mutation,则为空。
  • merge_algorithm (String) — 当前合并使用的算法。如果是 mutation,则为空。