eldenmoon commented on code in PR #66858:
URL: https://github.com/apache/doris/pull/66858#discussion_r3900189778
##########
be/src/exprs/function/array/function_array_utils.cpp:
##########
@@ -55,12 +55,28 @@ bool extract_column_array_info(const IColumn& src,
ColumnArrayExecutionData& dat
}
if (data.output_as_variant &&
data.nested_type->get_primitive_type() != PrimitiveType::TYPE_VARIANT)
{
- // set variant root column/type to from column/type
- auto variant = ColumnVariant::create(0, data.variant_enable_doc_mode);
- auto nullable_nested_type = make_nullable(data.nested_type);
- auto nullable_col = make_nullable(data.nested_col);
- variant->create_root(nullable_nested_type,
std::move(*nullable_col).mutate());
- data.nested_col = variant->get_ptr();
+ ColumnPtr variant;
+ const auto nulls = data.nested_nullmap_data == nullptr
+ ?
CastWrapper::variant_v2_internal::ForcedNulls {}
+ :
CastWrapper::variant_v2_internal::ForcedNulls {
+ data.nested_nullmap_data,
data.nested_col->size()};
+ Status status;
Review Comment:
为什么是在这里 cast,而不是在 CAST 函数里?如果要修改,形成单独的 commit
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]