开发者社区> 问答> 正文

Hologres对于decimal数据相乘报错code: kActorInvokeError ...

已解决

Hologres对于decimal数据相乘报错code: kActorInvokeError msg: "HGERR_code 22003 HGERR_msge numeric field overflow HGERR_detl A field with precision 38, scale 36 must round to an absolute value less than 10^2.

展开
收起
提个问题 2024-06-10 16:10:28 12 0
1 条回答
写回答
取消 提交回答
  • 开发者社区问答官方账号
    官方回答
    采纳回答
    报错信息:对于decimal数据相乘报错:
    报错一:ERROR: code: kActorInvokeError msg: "HGERR_code 22003 HGERR_msge numeric field overflow HGERR_detl A field with precision 38, scale 36 must round to an absolute value less than 10^2. HGERR_ctxt HGERR_erno 2 HGERR_end" err_data filename: "FunctionsCast.cc" lineno: 323 funcname: "DecimalOverflowCheck" sqlerrcode: 50331778 message: "numeric field overflow" detail: "A field with precision 38, scale 36 must round to an absolute value less than 10^2." context: " 
    报错二:ERROR: status { code: SERVER_INTERNAL_ERROR message: "[FunctionsArithmetic.h:971 apply] HGERR_code xx HGERR_msge value \"%s\" is out of range for %s HGERR_end[query_id:xxx][xxx]" err_data { filename: "FunctionsArithmetic.h" lineno: xx funcname: "apply" sqlerrcode: xx message: "value \"%s\" is out of range for %s" context: "[query_id:xxx]" } } 
    报错原因: 对于decimal类型的字段进行相乘,例如:numeric(38, 18)乘以numeric(38, 18) 会得到numeric(38, 36),小数点保存太多位数导致溢出。从而报错,出现问题版本:1.1.21及以下版本。
    解决方案: 升级至最新版本。
    2024-06-10 16:10:30
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
实时数仓Workshop(广州站)- 李佳林 立即下载
阿里云实时数仓Hologres技术揭秘2.0 立即下载
实时数仓Hologres技术实战一本通2.0版(下) 立即下载