简体   繁体   中英

Amazon Athena - Error Create Iceberg table

I used this as a reference to create a Create statement that creates an Apache Iceberg table in Amazon Athena's Query Editor. Below.

CREATE TABLE iceberg_table (id int, data string, category string)
PARTITIONED BY (category, bucket(16, id))
LOCATION 's3://xxxxxxxx/iceberg_table/'
TBLPROPERTIES (
        'table_type' = 'ICEBERG',
        'format' = 'parquet',
        'write_target_data_file_size_bytes' = '536870912'
)

When I ran this, I got the following error.

Iceberg cannot found the requested entity

Also, when I ran Explain, I got the following message

line 2:1: mismatched input 'PARTITIONED'. Expecting: 'COMMENT', 'WITH', <EOF>

So, I think there is a problem with the Create statement I created. I checked to see if extra spaces had been removed or if the quotes were incorrect, but could not find the cause. I would appreciate your help.

Thanks.

The code works fine for me. I'm using Athena with Engine v3, maybe that's the cause?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM