This is an automated email from the ASF dual-hosted git repository.
morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/master by this push:
new 712c078c615 [fix](be) Adapt nullable column unnesting to new interface
(#66474)
712c078c615 is described below
commit 712c078c615ff27e3080242bc68c861d08006251
Author: linrrarity <[email protected]>
AuthorDate: Wed Aug 5 17:36:42 2026 +0800
[fix](be) Adapt nullable column unnesting to new interface (#66474)
Related PR: conflict between https://github.com/apache/doris/pull/66242
and https://github.com/apache/doris/pull/66031
Problem Summary:
fix be compile:
```text
In file included from ../src/exprs/function/ai/ai_functions.cpp:19:
In file included from ../src/exprs/function/ai/ai_classify.h:20:
../src/exprs/function/ai/ai_functions.h:312:66: error: too few arguments to
function call, expected 2, have 0
312 |
prompt_columns.emplace_back(argument.unnest_nullable().column);
| ~~~~~~~~~~~~~~~~~~~~~~~~ ^
../src/core/block/column_with_type_and_name.h:86:27: note:
'unnest_nullable' declared here
86 | ColumnWithTypeAndName unnest_nullable(const NullableColumnInfo&
info,
| ^
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
87 | bool
replace_null_data_to_default) const;
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../src/exprs/function/ai/ai_functions.cpp:29:
../src/exprs/function/ai/embed.h:74:56: error: too few arguments to
function call, expected 2, have 0
74 | ColumnPtr input_column = input.unnest_nullable().column;
| ~~~~~~~~~~~~~~~~~~~~~ ^
../src/core/block/column_with_type_and_name.h:86:27: note:
'unnest_nullable' declared here
86 | ColumnWithTypeAndName unnest_nullable(const NullableColumnInfo&
info,
| ^
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
87 | bool
replace_null_data_to_default) const;
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 errors generated.
```
---
be/src/exprs/function/ai/ai_functions.h | 7 ++++++-
be/src/exprs/function/ai/embed.h | 6 +++++-
be/test/ai/ai_function_test.cpp | 8 +++++++-
3 files changed, 18 insertions(+), 3 deletions(-)
diff --git a/be/src/exprs/function/ai/ai_functions.h
b/be/src/exprs/function/ai/ai_functions.h
index b074b6cc584..2ed287b37ad 100644
--- a/be/src/exprs/function/ai/ai_functions.h
+++ b/be/src/exprs/function/ai/ai_functions.h
@@ -309,7 +309,12 @@ protected:
VectorizedUtils::update_null_map(result_null_map->get_data(),
nullable.get_null_map_data(),
is_const);
}
- prompt_columns.emplace_back(argument.unnest_nullable().column);
+ prompt_columns.emplace_back(
+ argument.unnest_nullable(argument.type->is_nullable()
+ ?
argument.get_nullable_column_info()
+ : NullableColumnInfo {},
+ false)
+ .column);
}
if (result_null_map &&
diff --git a/be/src/exprs/function/ai/embed.h b/be/src/exprs/function/ai/embed.h
index f193a1c171c..d10349fb69b 100644
--- a/be/src/exprs/function/ai/embed.h
+++ b/be/src/exprs/function/ai/embed.h
@@ -71,7 +71,11 @@ public:
return Status::OK();
}
- ColumnPtr input_column = input.unnest_nullable().column;
+ ColumnPtr input_column =
+ input.unnest_nullable(input.type->is_nullable() ?
input.get_nullable_column_info()
+ :
NullableColumnInfo {},
+ false)
+ .column;
PrimitiveType input_type =
remove_nullable(input.type)->get_primitive_type();
if (input_type == PrimitiveType::TYPE_JSONB) {
return _execute_multimodal_embed(context, block, result,
input_rows_count, config,
diff --git a/be/test/ai/ai_function_test.cpp b/be/test/ai/ai_function_test.cpp
index 976eaddd5bc..f8260bbde0a 100644
--- a/be/test/ai/ai_function_test.cpp
+++ b/be/test/ai/ai_function_test.cpp
@@ -218,7 +218,13 @@ Columns get_prompt_columns(const Block& block, const
ColumnNumbers& arguments) {
Columns prompt_columns;
prompt_columns.reserve(arguments.size() - 1);
for (size_t i = 1; i < arguments.size(); ++i) {
-
prompt_columns.emplace_back(block.get_by_position(arguments[i]).unnest_nullable().column);
+ const auto& argument = block.get_by_position(arguments[i]);
+ prompt_columns.emplace_back(
+ argument.unnest_nullable(argument.type->is_nullable()
+ ?
argument.get_nullable_column_info()
+ : NullableColumnInfo {},
+ false)
+ .column);
}
return prompt_columns;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]