diff --git a/be/src/vec/functions/function_jsonb.cpp b/be/src/vec/functions/function_jsonb.cpp index 9a1716136b0700f..1e53a3581714041 100644 --- a/be/src/vec/functions/function_jsonb.cpp +++ b/be/src/vec/functions/function_jsonb.cpp @@ -1158,7 +1158,7 @@ class FunctionJsonbContains : public IFunction { static FunctionPtr create() { return std::make_shared>(); } DataTypePtr get_return_type_impl(const DataTypes& arguments) const override { - return make_nullable(std::make_shared()); + return std::make_shared(); } DataTypes get_variadic_argument_types_impl() const override { return Impl::get_variadic_argument_types(); @@ -1167,8 +1167,6 @@ class FunctionJsonbContains : public IFunction { return get_variadic_argument_types_impl().size(); } - bool use_default_implementation_for_nulls() const override { return false; } - Status execute_impl(FunctionContext* context, Block& block, const ColumnNumbers& arguments, size_t result, size_t input_rows_count) const override { return Impl::execute_impl(context, block, arguments, result, input_rows_count); @@ -1244,8 +1242,7 @@ struct JsonbContainsUtil { res->insert_data(const_cast((char*)&contains_value), 0); } - block.replace_by_position(result, - ColumnNullable::create(std::move(res), std::move(null_map))); + block.replace_by_position(result, std::move(res)); return Status::OK(); } }; @@ -1295,13 +1292,11 @@ class FunctionJsonbDepth : public IFunction { static FunctionPtr create() { return std::make_shared(); } DataTypePtr get_return_type_impl(const DataTypes& arguments) const override { - return make_nullable(std::make_shared()); + return std::make_shared(); } size_t get_number_of_arguments() const override { return 1; } - bool use_default_implementation_for_nulls() const override { return false; } - Status execute_impl(FunctionContext* context, Block& block, const ColumnNumbers& arguments, size_t result, size_t input_rows_count) const override { DCHECK_GE(arguments.size(), 1); @@ -1332,8 +1327,7 @@ class FunctionJsonbDepth : public IFunction { res_data[i] = value->depth(); } - block.replace_by_position( - result, ColumnNullable::create(std::move(col_result), std::move(null_map))); + block.replace_by_position(result, std::move(col_result)); return Status::OK(); } };