Omega359 commented on code in PR #20436:
URL: https://github.com/apache/datafusion/pull/20436#discussion_r2836258111
##########
datafusion/functions/src/string/concat_ws.rs:
##########
@@ -268,28 +314,71 @@ impl ScalarUDFImpl for ConcatWsFunc {
}
}
- let mut builder = StringArrayBuilder::with_capacity(len, data_size);
- for i in 0..len {
- if !sep.is_valid(i) {
- builder.append_offset();
- continue;
+ match return_datatype {
+ DataType::Utf8View => {
Review Comment:
I wonder if all this duplicated code could be eliminated with an approach
similar to
https://github.com/apache/datafusion/blob/2a08013af3ccf703bee202c959b40bb0d35bdea1/datafusion/functions-nested/src/string.rs#L792
?
--
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]