zclllyybb commented on code in PR #18692:
URL: https://github.com/apache/doris/pull/18692#discussion_r1168127145
##########
be/src/vec/functions/function_string.h:
##########
@@ -2292,30 +2292,76 @@ class FunctionStringLocatePos : public IFunction {
Status execute_impl(FunctionContext* context, Block& block, const
ColumnNumbers& arguments,
size_t result, size_t input_rows_count) override {
- auto col_substr =
-
block.get_by_position(arguments[0]).column->convert_to_full_column_if_const();
- auto col_str =
+ const auto& left = block.get_by_position(arguments[0]);
+ const auto& right =
Review Comment:
maybe the right column seems more likely to be constant? If so, we should
optimize for `rcol` but not `lcol` and use
`default_preprocess_parameter_columns` to deal with other columns. Then our
dispatcher could distinguish by wether `lcol` and `pos` are all const.
--
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]