Snowflake Storage for Apache Iceberg™ Tables¶
This preview introduces support for Snowflake Storage for Apache Iceberg™ Tables.
Just like standard Snowflake tables, this feature lets you to create Snowflake-managed Iceberg tables in Snowflake. With this option, Snowflake stores and manages the Iceberg table files for you by using Snowflake (internal) storage, so you don't need to set up access to external cloud storage.
This feature works with the Snowflake Horizon Catalog, so you can use an external query engine to connect to an Iceberg table that uses Snowflake storage. For more information, see 通过 Snowflake Horizon 目录使用外部引擎查询 Apache Iceberg™ 表. In addition, you can query these same tables in Snowflake.
备注
This feature is currently available only for accounts hosted on Amazon Web Services (AWS) or Azure.
Create an Iceberg table with Snowflake storage¶
Create an Iceberg table that uses Snowflake storage:
CREATE ICEBERG TABLE my_iceberg_table_internal (col1 int) CATALOG = SNOWFLAKE EXTERNAL_VOLUME = SNOWFLAKE_MANAGED;
The
CATALOGmust beSNOWFLAKE. However, the default catalog at the account level is set to SNOWFLAKE, so you can omit theCATALOGparameter if you haven't changed this default. For more information on setting a default catalog, see 在账户、数据库或架构级别设置默认目录.The
EXTERNAL_VOLUMEmust beSNOWFLAKE_MANAGED. SNOWFLAKE_MANAGED is a reserved external volume name that tells Snowflake to use Snowflake Storage for the Iceberg table. However, the default external volume at the account level is set to SNOWFLAKE_MANAGED, so you can omit theEXTERNAL_VOLUMEparameter if you haven't changed this default. For more information on setting a default external volume, see 在账户、数据库或架构级别设置默认外部卷.
警告
The Iceberg table that you create uses catalog-vended credentials. When you clone an Iceberg table that uses catalog-vended credentials, the cloned table shares the same base location as the source table. The same credentials can be used to access the shared base location, so the cloned table has write access to the source table.
Considerations¶
Consider the following when you work with Iceberg tables that use Snowflake storage:
This feature is currently available only for accounts hosted on Amazon Web Services (AWS) or Azure.
During the preview period, you can see information about the storage usage for a table in the
STAGE_BYTEScolumn of the STORAGE_USAGE 视图.