分区用的是记录中的字段,没有用到processing time或者event time去生成分区。 发现只要给hive的表加上以下这三个属性就可以马上提交分区到metastore了。 'sink.partition-commit.trigger'='process-time' 'sink.partition-commit.delay'='0s' 'sink.partition-commit.policy.kind'='metastore,success-file'
-- kingdomad 在 2020-12-21 23:27:49,"赵一旦" <hinobl...@gmail.com> 写道: >即使不是flink写入,其他方式写入也需要这样做的哈。 > >r pp <pr123sha...@gmail.com> 于2020年12月21日周一 下午9:28写道: > >> 程序中,创建表后,执行命令。 >> >> kingdomad <kingdo...@163.com> 于2020年12月21日周一 下午4:55写道: >> >> > >> flink1.11.2写hive3.12的分区表,flink新创建的分区数据hive无法识别,在hdfs上能看到写入了文件,但是hive读取不了分区。 >> > 需要执行msck repair table修复分区表后,hive才能读取到数据。 >> > 求助大佬,要如何解决。 >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > >> > -- >> > >> > kingdomad >> > >> > >>