msck修复表查询不工作

fykwrbwg  于 2021-06-26  发布在  Hive
关注(0)|答案(0)|浏览(216)

我以这样的配置单元格式将分区数据存储在s3中。

/bucket/year=2017/month=02/date=20
/bucket/year=2017/month=02/date=21

我在雅典娜创建了一个外部表

CREATE EXTERNAL TABLE mts_prod_8(
event struct<type:string, id:string>,
longitude double,
application string,
latitude double,
device_id string,
trip_id string
)

PARTITIONED BY (year string, month string, date string)
ROW FORMAT SERDE 'org.apache.hive.hcatalog.data.JsonSerDe'
WITH SERDEPROPERTIES ('serialization.format' = '1') LOCATION 's3://mts-data/dispatcher/'

每天在s3中添加新的分区,为了将其加载到athena表中,我运行以下查询

MSCK REPAIR TABLE TABLE_NAME

但不知怎的,上面的查询失败了,元数据没有加载。
我完全陷进去了。
任何帮助都将受到感谢。
提前谢谢

暂无答案!

目前还没有任何答案,快来回答吧!

相关问题