zanmato1984 opened a new pull request, #48639:
URL: https://github.com/apache/arrow/pull/48639

   ### Rationale for this change
   
   When dispatching binary arithmetic and comparison kernels, we do a special 
casting ahead for decimal arguments. If one argument is decimal and another is 
the type not castable (e.g., string) to decimal, an assertion fires. On the 
other hand, we have a graceful way to error on dispatch failure in the general 
kernel dispatching path after this special casting:
   ```
   Function 'greater' has no kernel matching input types (string, double)
   ```
   We want to unify the error path for decimal.
   
   ### What changes are included in this PR?
   
   Bypass the decimal casting early and not error out if we see the other 
argument is not castable to decimal, and let the subsequent general kernel 
dispatching path to handle the error gracefully.
   
   ### Are these changes tested?
   
   Test included.
   
   ### Are there any user-facing changes?
   
   None.


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

Reply via email to