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/07 20:31:10 UTC

[GitHub] [arrow-datafusion] WinkerDu opened a new issue, #2482: Numeric, String, Boolean comparisons with literal `NULL`

WinkerDu opened a new issue, #2482:
URL: https://github.com/apache/arrow-datafusion/issues/2482

   **Is your feature request related to a problem or challenge? Please describe what you are trying to do.**
   As discuss in #1179 , there is bug when Numeric, String, Boolean comparisons work with literal `NULL`
   
   **Toproduce**
   ```
   > select * from (VALUES (1, 'foo' ,2.3), (2, 'bar', 5.4)) as t;
   +---------+---------+---------+
   | column1 | column2 | column3 |
   +---------+---------+---------+
   | 1       | foo     | 2.3     |
   | 2       | bar     | 5.4     |
   +---------+---------+---------+
   2 rows in set. Query took 0.004 seconds.
   > select column1 < null from (VALUES (1, 'foo' ,2.3), (2, 'bar', 5.4)) as t;
   Plan("'Int64 < Utf8' can't be evaluated because there isn't a common type to coerce the types to")
   > select column2 < null from (VALUES (1, 'foo' ,2.3), (2, 'bar', 5.4)) as t;
   ArrowError(ExternalError(Internal("compute_utf8_op_scalar for 'lt' failed to cast literal value NULL")))
   > select column3 < null from (VALUES (1, 'foo' ,2.3), (2, 'bar', 5.4)) as t;
   Plan("'Float64 < Utf8' can't be evaluated because there isn't a common type to coerce the types to")
   ```
   
   **Describe the solution you'd like**
   - Introduces `null_coercion` to `comparison_eq_coercion` and `comparison_order_coercion`
   - Enhances binary expression macros to support `NULL` scalar value comparing with array, like `binary_array_op_dyn_scalar`
   


-- 
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.apache.org

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


[GitHub] [arrow-datafusion] WinkerDu closed issue #2482: Numeric, String, Boolean comparisons with literal `NULL`

Posted by GitBox <gi...@apache.org>.
WinkerDu closed issue #2482: Numeric, String, Boolean comparisons with literal `NULL`
URL: https://github.com/apache/arrow-datafusion/issues/2482


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


[GitHub] [arrow-datafusion] WinkerDu commented on issue #2482: Numeric, String, Boolean comparisons with literal `NULL`

Posted by GitBox <gi...@apache.org>.
WinkerDu commented on issue #2482:
URL: https://github.com/apache/arrow-datafusion/issues/2482#issuecomment-1133198999

   closed by #2481 


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