zxealous commented on code in PR #15043:
URL: https://github.com/apache/doris/pull/15043#discussion_r1048086705


##########
be/src/vec/functions/function_string.h:
##########
@@ -893,22 +893,21 @@ class FunctionStringConcatWs : public IFunction {
         const auto& src_array_offsets = array_column.get_offsets();
         size_t current_src_array_offset = 0;
 
+        auto& sep_offsets = *offsets_list[0];
+        auto& sep_chars = *chars_list[0];
+        auto& sep_nullmap = *null_list[0];
+        int sep_size = sep_offsets[0];
+        const char* sep_data = reinterpret_cast<const char*>(&sep_chars[0]);
+        std::string_view sep(sep_data, sep_size);
+

Review Comment:
   If it is moved outside the loop, it will always use the data in the first 
row as the separator?



-- 
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: commits-unsubscr...@doris.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org
For additional commands, e-mail: commits-h...@doris.apache.org

Reply via email to