- 错误信息
QL 错误 [1105] [HY000]: errCode = 2, detailMessage = (172.18.36.153)[INTERNAL_ERROR]Function json_set get failed, expr is VectorizedFnCall[json_set](arguments=txt, String, String, String,return=Nullable(String)) and return type is Nullable(String).
- 使用语句
drop table if exists test.test;
create table test.test (
`id` varchar
,`txt` varchar
)
DUPLICATE KEY(`id`)
DISTRIBUTED BY HASH(`txt`) BUCKETS 1
;
insert into test.test(id,txt)
values('11','{"a":"11"}');
select * from test.test;
-- 官方文档样例
-- select json_set('{"k": 1}', "$.j", 2);
select
id
,txt
,json_set(txt, "$.a", "111") xxx
from test.test a
;