You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/08/24 21:17:41 UTC

[GitHub] [arrow-rs] jorgecarleitao commented on a change in pull request #706: Implement `regexp_matches_utf8`

jorgecarleitao commented on a change in pull request #706:
URL: https://github.com/apache/arrow-rs/pull/706#discussion_r695223816



##########
File path: arrow/src/compute/kernels/comparison.rs
##########
@@ -450,6 +450,250 @@ pub fn nlike_utf8_scalar<OffsetSize: StringOffsetSizeTrait>(
     Ok(BooleanArray::from(data))
 }
 
+/// Perform SQL `array ~ regex_array` operation on [`StringArray`] / [`LargeStringArray`].
+pub fn regexp_matches_utf8<OffsetSize: StringOffsetSizeTrait>(

Review comment:
       imo achieving full compatibility with postgres is beyond the scope of the `arrow-rs` crate. IMO the least surprising option here is an implementation of the regex semantics declared in the `regex` crate. Users interested in the postgres semantics are a subset of all users - postgres semantics is something relatively specific to databases.
   
   Also, afaik achieving postgres semantics is relatively difficult as it requires a regex parser to act as the postgres one (but I may be mistaken here).
   
   A possible approach is to move both of these kernels to datafusion and keep a non-postgres, `regex`-crate specific one here.




-- 
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: github-unsubscribe@arrow.apache.org

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