SQL 错误 [40000] [42000]: Error while compiling statement: FAILED

时间:2024-10-18 10:19:27

错误如下:

SQL 错误 [40000] [42000]: Error while compiling statement: FAILED: SemanticException table is not partitioned but partition spec exists: {month=null, day=null}

解决方法:

解决办法,在sql语句前面加

SET hive.exec.dynamic.partition = true ; 
SET hive.exec.dynamic.partition.mode = nonstrict;

在这里插入图片描述
在这里插入图片描述