可能的解决方案是创建具有相同模式的表并将位置设置为所需位置,然后使用Hive和动态分区加载数据:
create table T2 like T1; Alter table T2 set location = 'your destination location'; set hive.exec.dynamic.partition=true; set hive.exec.dynamic.partition.mode=nonstrict; Insert overwrite table T2 partition (dt) select * from T1 distribute by dt;