edmondop commented on code in PR #7897:
URL: https://github.com/apache/arrow-datafusion/pull/7897#discussion_r1367795554
##########
datafusion/physical-expr/src/array_expressions.rs:
##########
@@ -1478,6 +1478,28 @@ macro_rules! to_string {
}};
}
+
+/// Array_union SQL function
+pub fn array_union(args: &[ArrayRef]) -> Result<ArrayRef> {
Review Comment:
@comphead the current implementation is buggy, because he doesn't remove
duplicates. I tried a couple of ways and after discussing in the
arrow-datafusion Slack channel, it seems the simpler approach would be to
convert the array to rows and de-duplicate, then back to rows. What do you
think?
https://docs.rs/arrow-row/latest/arrow_row/struct.RowConverter.html#method.convert_rows
--
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]