You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "viirya (via GitHub)" <gi...@apache.org> on 2023/02/01 19:34:05 UTC

[GitHub] [arrow-datafusion] viirya opened a new issue, #5150: Arithmetic scalar operation doesn't work with DictionaryArray

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

   **Describe the bug**
   
   We've integrated Datafusion but recently saw an exception during evaluating arithmetic operation between DictionaryArray and scalar value:
   
   ```
   'Dictionary(Int32, Int64) + Int64' can't be evaluated because there isn't a common type to coerce the types to.  
   ```
   
   A few issues around this:
   
   * `binary_operator_data_type` calls `coerce_types` to coerce left and right data types, but it doesn't consider `Dictionary` type. in `mathematics_numerical_coercion`.
   * In `BinaryExpr.evaluate_array_scalar`, the macros for arithmetic operations (`Plus` etc.) also don't consider `DictionaryArray`.
   
   **To Reproduce**
   Steps to reproduce the behavior:
   
   **Expected behavior**
   A clear and concise description of what you expected to happen.
   
   **Additional context**
   Add any other context about the problem 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.apache.org

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


[GitHub] [arrow-datafusion] liukun4515 closed issue #5150: Arithmetic scalar operation doesn't work with DictionaryArray

Posted by "liukun4515 (via GitHub)" <gi...@apache.org>.
liukun4515 closed issue #5150: Arithmetic scalar operation doesn't work with DictionaryArray
URL: https://github.com/apache/arrow-datafusion/issues/5150


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