ChenMiaoi commented on PR #50151: URL: https://github.com/apache/doris/pull/50151#issuecomment-2833796062
> If you want to implements `json path` param, you can refer to the following ideas:如果要实现 `json 路径`参数,可以参考以下思路: First, replace `SimdJSONParser::Element` with `JsonbDocument`.首先,将 `SimdJSONParser::Element` 替换为 `JsonbDocument`。 Second, find all elements that match the path.其次,找到与路径匹配的所有元素。 Third, use the elements find in second step as the root element to find their child elements.第三步,使用第二步中找到的元素作为根元素来查找其子元素。 > > A test case: 一个测试用例: > > ``` > select json_search('["abc", [{"k": "10"}, "10"], [{"x":"10"}], {"y":"bcd"}]', 'all', '10', null, '$[*][*]'); > > -- ["$[1][0].k", "$[1][1]", "$[2][0].x"] > ``` ok,I'll think about it. Except for the first step, my solution is no different from yours. I'll look at JsonDocument. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org