yangzhg commented on a change in pull request #6504: URL: https://github.com/apache/incubator-doris/pull/6504#discussion_r699800543
########## File path: be/src/exprs/json_functions.cpp ########## @@ -108,6 +108,96 @@ DoubleVal JsonFunctions::get_json_double(FunctionContext* context, const StringV } } +StringVal JsonFunctions::json_array(FunctionContext* context, int num_args, + const StringVal* json_str) { + if (json_str->is_null) { + return StringVal::null(); + } + rapidjson::Value array_obj(rapidjson::kArrayType); + rapidjson::Document document; + rapidjson::Document::AllocatorType& allocator = document.GetAllocator(); + //flag: The number it contains represents the type of previous parameters + std::string flag((char*)json_str[num_args - 1].ptr, json_str[num_args - 1].len); + DCHECK(num_args-1==flag.length()); Review comment: ```suggestion DCHECK_EQ(num_args - 1, flag.length()); ``` -- 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