使用 CAST 函数将 STRING 转为 BIGI python NT:
SELECT CAST('00321' AS BIGINT) FROM table;
As a BIGINT it will show on the screen and in delimited text files as 321.
参考:Hive - Converting a android string to bigint
补充 知识 : hive php 中bigint和varchar字段做关联,关联数据错误的 js 解决方法
把bigint和varchar都隐式转换成String类型的就可以关联出正确的结果了
cast(t1.PARTY_NUM as string)=cast(t12.customerId as string)
以上这篇hive中将string数据转为bigint的操作就是小编分享给大家的全部内容了,希望能给大家一个参考,也希望大家多多支持我们。 编程客栈
查看更多关于hive中将string数据转为bigint的操作的详细内容...
声明:本文来自网络,不代表【好得很程序员自学网】立场,转载请注明出处:http://haodehen.cn/did177706