搜索结果显示列名
set hive.cli.print.header=true;
set hive.resultset.use.unique.column.names=false;
启用动态分区
set hive.exec.dynamic.partition=true;
set hive.exec.dynamic.partition.mode=nonstrict;
添加UDF
add jar 上传的jar包路径; # 作用:将该jar包添加到hive的classpath
create temporary function temp_func as “com.lzl.hive.Lower”; # 引号里是自定义UDF类路径
然后即可以使用该函数
select temp_func …