[fix](json function) Fix the slow performance of get_json_path when processing JSONB (#24631)
When processing JSONB, automatically convert to jsonb_extract_string
This commit is contained in:
@ -273,6 +273,10 @@ struct GetJsonNumberType {
|
||||
using ColumnType = typename NumberType::ColumnType;
|
||||
using Container = typename ColumnType::Container;
|
||||
|
||||
static DataTypes get_variadic_argument_types_impl() {
|
||||
return {std::make_shared<DataTypeString>(), std::make_shared<DataTypeString>()};
|
||||
}
|
||||
|
||||
static void get_json_impl(rapidjson::Value*& root, const std::string_view& json_string,
|
||||
const std::string_view& path_string, rapidjson::Document& document,
|
||||
typename NumberType::T& res, UInt8& null_map) {
|
||||
@ -526,6 +530,9 @@ struct GetJsonString {
|
||||
res_offsets);
|
||||
}
|
||||
}
|
||||
static DataTypes get_variadic_argument_types_impl() {
|
||||
return {std::make_shared<DataTypeString>(), std::make_shared<DataTypeString>()};
|
||||
}
|
||||
};
|
||||
|
||||
template <int flag>
|
||||
|
||||
Reference in New Issue
Block a user