1.设置执行引擎
set hive.execution.engine=mr;
set hive.execution.engine=spark;设置为mr则调用Hadoop的mr执行;设置执行引擎为spark则调用spark执行任务。若有条件设置为Spark,因为运行比Hadoop的mr快。 2.启动动态分区功能 set hive.exec.dynamic.partition=true; 3.允许全部分区都是动态分区 set hive.exec.dynamic.partition.mode=nostrick; 4.设置分区参数 SET hive.exec.max.dynamic.partitions=2048;(如果自动分区数大于这个参数,将会报错) SET hive.exec.max.dynamic.partitions.pernode=2048; 5.