hive
hive
cg6
这个作者很懒,什么都没留下…
展开
-
hive - 函数使用系列
hive - 函数使用系列原创 2022-08-01 16:12:05 · 594 阅读 · 0 评论 -
hive - 开发遇到的问题与解决系列
hive - 乱码原创 2022-07-18 17:33:57 · 591 阅读 · 0 评论 -
hive-sql 性能优化
hive sql 性能优化原创 2022-06-13 11:21:00 · 270 阅读 · 0 评论 -
hive - 字符串string和bigint类型的坑
hive 的string与bigint的比较原创 2022-06-10 13:45:20 · 3868 阅读 · 1 评论 -
hive - return code (数字) from org.apache.hadoop.hive.ql.exec错误系列集合
hvie - return code 1 from org.apache.hadoop.hive.ql.exec.MoveTask. Unable to move source hdfs://XXX to destination hdfs://xxx原因:执行hive任务的用户对hdfs://xxx没有操作权限解决:对目录授权命令:hdfs dfs -chown -R use:group hdfs://xxx...原创 2022-04-20 18:41:39 · 6604 阅读 · 3 评论 -
hvie merge into 批量更新
hvie merge into 批量更新一、使用条件2、建表要求一、使用条件hive2.2.0及之后的版本支持使用merge into 语法,使用源表数据批量目标表的数据。使用该功能还需做如下配置1、参数配置set hive.support.concurrency = true;set hive.enforce.bucketing = true;set hive.exec.dynamic.partition.mode = nonstrict;set hive.txn.manager = org转载 2022-02-23 15:10:45 · 1359 阅读 · 0 评论 -
hive Unexpected column vector type LIST
hive Unexpected column vector type LIST现象描述:表A字段名数据类型idbigintpatharray表B字段名数据类型idbigintnamestringa_idbigint表C字段名数据类型idbigintb_idbigint异常SQL:报表:Unexpected column vector type LISTselect A.id原创 2022-02-16 10:21:13 · 1480 阅读 · 2 评论 -
Unauthorized connection for super-user: hive from IP
报错信息:java.util.concurrent.ThreadPoolExecutor$Worker:run:ThreadPoolExecutor.java:624, java.lang.Thread:run:Thread.java:748, *java.lang.RuntimeException:java.lang.RuntimeException: org.apache.hadoop.ipc.RemoteException(org.apache.hadoop.security.authorize.Au原创 2021-11-30 10:23:44 · 4090 阅读 · 0 评论 -
ZooKeeper node /hiveserver2 is not ready yet
报错信息:ZooKeeper node /hiveserver2 is not ready yet现象:HIVE METASTORE 服务显示正常,启动 HIVESERVER2 报错原因:HIVE METASTORE 服务显示正常,但服务无法连接解决:重启 HIVE METASTORE , 再重启 HIVESERVER2 即可...原创 2021-11-30 10:23:06 · 2206 阅读 · 4 评论 -
might be less than configured maximum allocation=<memory:2048,
might be less than configured maximum allocation=报错:org.apache.tez.dag.api.TezException: org.apache.hadoop.yarn.exceptions.InvalidResourceRequestException: Invalid resource request, requested resource type=[memory-mb] < 0 or greater than maximum allowed原创 2021-11-30 10:20:07 · 487 阅读 · 0 评论 -
hive Unable to fetch table/MetaException(message:java.lang.NullPointerException)
@[TOC](hive Unable to fetch table/MetaException(message:java.lang.NullPointerException))现象:无法 操作表原因可能如下:1、hive 元数据有异常 (常见是此种情况)解决方法:1、查询对应库下的表select TBL_ID from yz_dev_hive.TBLS where TBL_NAME ='dwd_fpf_anc_file_info' and DB_ID = (select DB_ID from原创 2021-11-29 15:54:37 · 2393 阅读 · 0 评论 -
Unable to instantiate org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClient
Unable to instantiate org.apache.hadoop.hive.ql.metadata.SessionHiveMetaStoreClienthive 服务没有开启原创 2021-11-29 15:54:06 · 192 阅读 · 0 评论 -
hive No matching method for class hiveUDF.PhoneTM with (string, int, int)
No matching method for class hiveUDF.PhoneTM with string, int, int原因: 1. 很不显眼的一个小问题,但是却非常严重:函数名应为 evaluate,我少写了一个a 2. 自定义UDF 函数只能在 beeline 连接方式下使用解决:1. 更正方法名为 evaluate 2. 在 beeline 连接方式下3. add jar 'jar包路径'4. 创建临时函数【当前会话有效】:create temporary functio原创 2021-11-29 15:53:29 · 844 阅读 · 0 评论 -
HIVESERVER2 服务启动失败
HIVESERVER2 服务启动失败HIVESERVER2 服务启动失败出现的现象: 1、 Caused by: java.lang.ClassNotFoundException: org.apache.hadoop.hive.ql.metadata.HiveException 2、会导致HIVE METASTORE 也失败原因可能有几方面:1、10000、9083端口被占用2、mysql 连接不上3、hive jar 包有问题解决1、排查端口占用情况,若存在端口占用,修改hive-s原创 2021-11-29 15:50:31 · 5732 阅读 · 1 评论 -
hive 表 join 操作,出现一个值匹配到多个不同值
hive 表 join 操作,出现一个值匹配到多个不同值原因:bigint和string比较时会隐式地都转换成double,java中double的精度只有15-16位(double可以精确的表示小于2^52=4503599627370496的数字)。当数字超过精度的时候就会比较不准确,出现你上面描述的现象。解决方案:1. 将string 转换为 bigint cast(c as bigint)再进行比较。2. 将bigint 转换为 stringcast(c as string)再进行比较。原创 2021-11-29 15:33:41 · 587 阅读 · 0 评论 -
hive full outer join - 出现数据重复
hive full outer join - 出现数据重复备注: full outer join 只能作用于两个表问题:full outer join 超过2个表,数据或出现多条重复数据解决:把要full outer join 的表,使用 UNION ALL 提取连接字段,同时 distinct 去重 且字段不为 null ,再 left join 需要 full outer join 的表 , 即可解决数据重复问题...原创 2021-11-29 15:39:06 · 1926 阅读 · 0 评论 -
hive - ERROR : Vertex failed, vertexName=Map 1
ERROR : Vertex failed, vertexName=Map 1解决:在 hive sql 脚本前,加上 set hive.vectorized.execution.enabled=false;原创 2021-11-29 15:30:10 · 4050 阅读 · 0 评论 -
hive - 执行脚本,无法输入用户密码,可以设置全局密码
执行脚本,无法输入用户密码,可以设置全局密码1、 执行脚本,无法输入用户密码,可以设置全局密码1、 执行脚本,无法输入用户密码,可以设置全局密码# 先设置mysql 密码 为当前环境变量,有时候再脚本内置脚本会使命令执行失败export MYSQL_PWD=passwd# 批量解锁 mysql 表脚本如下#!/bin/bashmysql -u root -e "show processlist" >> locked_log.txtfor line in `cat locked_原创 2021-11-29 15:26:52 · 479 阅读 · 0 评论