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

> Amazon S3、Azure、HDFS、またはローカルに保存された Apache Paimon テーブルへの読み取り専用のテーブル形式インターフェイスを提供します。

# paimon

export const ExperimentalBadge = () => {
  return <div className="experimentalBadge">
            <div className="experimentalIcon">
            <svg width="16" height="16" viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg">
                <path strokeWidth="1.25" d="M5.5 2H10.5" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" />
                <path strokeWidth="1.25" d="M9.50015 2V6.19625L13.4283 12.7425C13.4738 12.8183 13.4985 12.9049 13.4996 12.9934C13.5008 13.0818 13.4785 13.169 13.435 13.246C13.3914 13.323 13.3283 13.3871 13.2519 13.4317C13.1755 13.4764 13.0886 13.4999 13.0002 13.5H3.00015C2.91164 13.5 2.8247 13.4766 2.74822 13.432C2.67174 13.3874 2.60847 13.3233 2.56487 13.2463C2.52126 13.1693 2.49889 13.082 2.50004 12.9935C2.50119 12.905 2.52582 12.8184 2.5714 12.7425L6.50015 6.19625V2" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" />
                <path strokeWidth="1.25" d="M4.47656 9.56754C5.30344 9.41254 6.47656 9.47942 7.99969 10.25C10.0153 11.2707 11.4216 11.0569 12.2184 10.7282" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" />
            </svg>
        </div>
            実験的な機能です。 <u><a href="/docs/beta-and-experimental-features#experimental-features">詳細を見る。</a></u>
        </div>;
};

<div id="paimon-table-function">
  # paimon テーブル関数
</div>

Amazon S3、Azure、HDFS、またはローカルに保存された Apache [Paimon](https://paimon.apache.org/) テーブルに対して、読み取り専用のテーブル形式インターフェイスを提供します。

<div id="syntax">
  ## 構文
</div>

```sql theme={null}
paimon(url [,access_key_id, secret_access_key] [,format] [,structure] [,compression] [,extra_credentials])

paimonS3(url [,access_key_id, secret_access_key] [,format] [,structure] [,compression] [,extra_credentials])

paimonAzure(connection_string|storage_account_url, container_name, blobpath, [,account_name], [,account_key] [,format] [,compression_method])

paimonHDFS(path_to_table, [,format] [,compression_method])

paimonLocal(path_to_table, [,format] [,compression_method])
```

<div id="arguments">
  ## 引数
</div>

引数の説明は、それぞれテーブル関数 `s3`、`azureBlobStorage`、`HDFS`、`file` の引数の説明と同じです。
`format` は、Paimon テーブル内のデータファイルのフォーマットを表します。

`paimonS3` では、ClickHouse Cloud でロールベースアクセス用の `role_arn` を渡すために、オプションの `extra_credentials` パラメータを使用できます。設定手順については、[Secure S3](/ja/products/cloud/guides/data-sources/accessing-s3-data-securely) を参照してください。

<div id="returned-value">
  ### 戻り値
</div>

指定した構造を持ち、指定したPaimonテーブルのデータを読み取るためのテーブル。

<div id="defining-a-named-collection">
  ## named collection を定義する
</div>

以下は、URL と認証情報を保存するための named collection を設定する例です。

```xml theme={null}
<clickhouse>
    <named_collections>
        <paimon_conf>
            <url>http://test.s3.amazonaws.com/clickhouse-bucket/</url>
            <access_key_id>test</access_key_id>
            <secret_access_key>test</secret_access_key>
            <format>auto</format>
            <structure>auto</structure>
        </paimon_conf>
    </named_collections>
</clickhouse>
```

```sql theme={null}
SELECT * FROM paimonS3(paimon_conf, filename = 'test_table')
DESCRIBE paimonS3(paimon_conf, filename = 'test_table')
```

<div id="aliases">
  ## 別名
</div>

現在、テーブル関数 `paimon` は `paimonS3` の別名です。

<div id="virtual-columns">
  ## 仮想カラム
</div>

* `_path` — ファイルのパス。型: `LowCardinality(String)`.
* `_file` — ファイル名。型: `LowCardinality(String)`.
* `_size` — ファイルサイズ (バイト単位) 。型: `Nullable(UInt64)`. ファイルサイズが不明な場合、値は `NULL` です。
* `_time` — ファイルの最終更新時刻。型: `Nullable(DateTime)`. 時刻が不明な場合、値は `NULL` です。
* `_etag` — ファイルの etag。型: `LowCardinality(String)`. etag が不明な場合、値は `NULL` です。

<div id="data-types-supported">
  ## サポートされているデータ型
</div>

| Paimon データ型                       | ClickHouse データ型   |
| --------------------------------- | ----------------- |
| BOOLEAN                           | Int8              |
| TINYINT                           | Int8              |
| SMALLINT                          | Int16             |
| INTEGER                           | Int32             |
| BIGINT                            | Int64             |
| FLOAT                             | Float32           |
| DOUBLE                            | Float64           |
| STRING,VARCHAR,BYTES,VARBINARY    | String            |
| DATE                              | Date              |
| TIME(p),TIME                      | Time('UTC')       |
| TIMESTAMP(p) WITH LOCAL TIME ZONE | DateTime64        |
| TIMESTAMP(p)                      | DateTime64('UTC') |
| CHAR                              | FixedString(1)    |
| BINARY(n)                         | FixedString(n)    |
| DECIMAL(P,S)                      | Decimal(P,S)      |
| ARRAY                             | Array             |
| MAP                               | Map               |

<div id="partition-supported">
  ## サポートされているパーティション
</div>

Paimon のパーティションキーでサポートされるデータ型:

* `CHAR`
* `VARCHAR`
* `BOOLEAN`
* `DECIMAL`
* `TINYINT`
* `SMALLINT`
* `INTEGER`
* `DATE`
* `TIME`
* `TIMESTAMP`
* `TIMESTAMP WITH LOCAL TIME ZONE`
* `BIGINT`
* `FLOAT`
* `DOUBLE`

<div id="see-also">
  ## 関連項目
</div>

* [Paimon クラスター テーブル関数](/ja/reference/functions/table-functions/paimonCluster)
