Apache Iceberg 資料表支援的資料類型 - Amazon Redshift

Amazon Redshift 自 2025 年 11 月 1 日起不再支援建立新的 Python UDF。如果您想要使用 Python UDF,請在該日期之前建立 UDF。現有 Python UDF 將繼續正常運作。如需詳細資訊,請參閱部落格文章

Apache Iceberg 資料表支援的資料類型

本主題說明 Redshift Spectrum 可從 Apache Iceberg 格式資料表讀取的支援資料類型。

Amazon Redshift 可以查詢包含下列資料類型的 Iceberg 資料表:

binary boolean date decimal double float int list long map string struct timestamp without time zone

如需 Iceberg 資料類型的相關資訊,請參閱 Apache Iceberg 文件中的 Iceberg 結構描述

下表顯示 Amazon Redshift 資料類型與 Iceberg 資料表資料類型之間的關係。

Iceberg 類型 Amazon Redshift 類型 備註
boolean boolean
- tinyint Iceberg 資料表不支援。
- smallint
int int
long bigint
double double precision
float real
decimal(P, S) decimal(P, S) P 是總位數,S 是小數部分的位數。
- char
string varchar(16384) 大於 16384 的字串會截斷至 16384
binary varbyte(64000)
date date
time -
timestamp timestamp
timestamptz timestamp
list<E> SUPER
map<K,V> SUPER
struct<...> SUPER
fixed(L) - Redshift Spectrum 目前不支援 fixed(L) 類型。
uuid - Redshift Spectrum 目前不支援 uuid 類型。
variant - Amazon Redshift 不支援 Iceberg V3。
geometry - Amazon Redshift 不支援 Iceberg V3。
geography - Amazon Redshift 不支援 Iceberg V3。
timestamp_ns - Amazon Redshift 不支援 Iceberg V3。
timestamptz_ns - Amazon Redshift 不支援 Iceberg V3。
Unknown - Amazon Redshift 不支援 Iceberg V3。

如需 Amazon Redshift 中資料類型的相關資訊,請參閱資料類型