This is an automated email from the ASF dual-hosted git repository.
eldenmoon pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-2.1 by this push:
new ffffbec49c6 [opt](function) Avoid create_column inside cast_column
function (#41775) (#42432)
ffffbec49c6 is described below
commit ffffbec49c62e37251d5625d0f90f644ceb9948f
Author: lihangyu <[email protected]>
AuthorDate: Thu Oct 24 23:05:02 2024 +0800
[opt](function) Avoid create_column inside cast_column function (#41775)
(#42432)
#41775
Co-authored-by: Mryange <[email protected]>
---
be/src/vec/common/schema_util.cpp | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/be/src/vec/common/schema_util.cpp
b/be/src/vec/common/schema_util.cpp
index 61b98bafd48..c5778a44e14 100644
--- a/be/src/vec/common/schema_util.cpp
+++ b/be/src/vec/common/schema_util.cpp
@@ -147,8 +147,7 @@ bool is_conversion_required_between_integers(const
TypeIndex& lhs, const TypeInd
}
Status cast_column(const ColumnWithTypeAndName& arg, const DataTypePtr& type,
ColumnPtr* result) {
- ColumnsWithTypeAndName arguments {
- arg, {type->create_column_const_with_default_value(1), type,
type->get_name()}};
+ ColumnsWithTypeAndName arguments {arg, {nullptr, type, type->get_name()}};
auto function = SimpleFunctionFactory::instance().get_function("CAST",
arguments, type);
if (!function) {
return Status::InternalError("Not found cast function {} to {}",
arg.type->get_name(),
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]