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 2022/05/25 01:03:07 UTC

[GitHub] [arrow-rs] MazterQyou commented on a diff in pull request #1738: Support casting `Utf8` to `Boolean`

MazterQyou commented on code in PR #1738:
URL: https://github.com/apache/arrow-rs/pull/1738#discussion_r881091531


##########
arrow/src/compute/kernels/cast.rs:
##########
@@ -280,6 +280,8 @@ pub fn can_cast_types(from_type: &DataType, to_type: &DataType) -> bool {
 ///
 /// Behavior:
 /// * Boolean to Utf8: `true` => '1', `false` => `0`
+/// * Utf8 to boolean: `true`, `yes`, `on`, `1` => `true`, `false`, `no`, `off`, `0` => `false`,

Review Comment:
   > unlike T and F which are computing primitives
   
   Should `true`, `false` shorter equivalents be left in? If yes, just `t` and `f`, or all variants? What about whitespace trimming?



-- 
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