can we create snowflake managed iceberg table directly on top of aws s3 bucket having files??? like snowflake external table

43 Views Asked by At

Currently i am loading the data from aws s3 bucket files to snowflake using copy command, but i dont want to store the data in snowflake, I have tried with snowflake external table it taking too much time to query i am thinking to go snowflake managed iceberg table , can you help me is it possible to create the iceberg table directly on top of aws s3 files or we need to load the data through snowflake by the way like copy or snowpipe could you please provide clear explanation it would be helpful

I am trying reduce the computation and storage cost to load the data from aws s3 to snowflake but snowflake external table takes too much time it increases the query running time , kindly clear on can we create the iceberg table on top of aws s3 files not using any copy command or insert command

1

There are 1 best solutions below

2
Dave Welden On

Configure external volume describes how to set up the external volume over the existing s3 buckets.

CREATE OR REPLACE EXTERNAL VOLUME exvol
   STORAGE_LOCATIONS =
      (
         (
            NAME = 'my-s3-us-west-2'
            STORAGE_PROVIDER = 'S3'
            STORAGE_BASE_URL = 's3://MY_EXAMPLE_BUCKET/'
            STORAGE_AWS_ROLE_ARN = 'arn:aws:iam::123456789012:role/myrole'
            ENCRYPTION=(TYPE='AWS_SSE_KMS' KMS_KEY_ID='arn:aws:kms:us-west-2:111111122222:key/1a1a11aa-aa1a-aaa1a-a1a1-000000000000')
         )
      );

Create Iceberg Table demonstrates creating an Iceberg Table directly over s3 storage. To create a Snowflake managed Iceberg Table, the command is as follows:

CREATE ICEBERG TABLE my_iceberg_table (amount int)
  CATALOG='SNOWFLAKE'
  EXTERNAL_VOLUME='my_external_volume'
  BASE_LOCATION='my/relative/path/from/extvol';