> ## Documentation Index
> Fetch the complete documentation index at: https://private-7c7dfe99-fix-nav-issues.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> MergeTree テーブルのデタッチされたパーツに関する情報を含むシステムテーブル

# system.detached_parts

<div id="purpose">
  ## 説明
</div>

[MergeTree](/ja/reference/engines/table-engines/mergetree-family/mergetree) テーブルのデタッチされたパーツに関する情報が含まれています。`reason` カラムには、そのパーツがデタッチされた理由が示されます。

ユーザーによってデタッチされたパーツでは、理由は空です。このようなパーツは、[ALTER TABLE ATTACH PARTITION|PART](/ja/reference/statements/alter/partition#attach-partitionpart) コマンドでアタッチできます。

他のカラムの説明については、[system.parts](/ja/reference/system-tables/parts) を参照してください。

パーツ名が無効な場合、一部のカラムの値は `NULL` になることがあります。このようなパーツは、[ALTER TABLE DROP DETACHED PART](/ja/reference/statements/alter/partition#drop-detached-partitionpart) で削除できます。

<div id="columns">
  ## カラム
</div>

* `database` ([String](/ja/reference/data-types)) — このパーツが属するデータベースの名前。
* `table` ([String](/ja/reference/data-types)) — このパーツが属するテーブルの名前。
* `partition_id` ([Nullable(String)](/ja/reference/data-types)) — このパーツが属するパーティションの識別子。
* `name` ([String](/ja/reference/data-types)) — このパーツの名前。
* `bytes_on_disk` ([UInt64](/ja/reference/data-types)) — すべてのデータパーツファイルの合計サイズ (バイト単位) 。
* `modification_time` ([DateTime](/ja/reference/data-types)) — データパーツを含むディレクトリが変更された時刻。通常、これはデタッチされた時刻に対応します。
* `disk` ([String](/ja/reference/data-types)) — このデータパーツを格納しているディスクの名前。
* `path` ([String](/ja/reference/data-types)) — このデータパーツのファイルがあるディスク上のパス。
* `reason` ([Nullable(String)](/ja/reference/data-types)) — このパーツがデタッチされた理由の説明。
* `min_block_number` ([Nullable(Int64)](/ja/reference/data-types)) — マージ後に現在のパーツを構成するデータパーツの最小番号。
* `max_block_number` ([Nullable(Int64)](/ja/reference/data-types)) — マージ後に現在のパーツを構成するデータパーツの最大番号。
* `level` ([Nullable(UInt32)](/ja/reference/data-types)) — マージツリーの深さ。0 は、現在のパーツが他のパーツのマージではなく insert によって作成されたことを意味します。
