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/07/21 18:15:05 UTC

[GitHub] [arrow-datafusion] alamb opened a new issue #766: Constant folding of to_timestamp uses different implementation than actual function call

alamb opened a new issue #766:
URL: https://github.com/apache/arrow-datafusion/issues/766


   **Describe the bug**
   A clear and concise description of what the bug is.
   Different implementations of string --> timestamp conversions are used if `to_timestamp()` is called in constant folding pass or in the actual compute kernel
   
   **To Reproduce**
   The function `string_to_timestamp_nanos` was moved upstream to arrow-rs and is used in constant folding here: https://github.com/apache/arrow-datafusion/blob/ffb195c8634fc537127eff1a082811d28e8fcc2b/datafusion/src/optimizer/constant_folding.rs
   ```
   use arrow::compute::kernels::cast_utils::string_to_timestamp_nanos;
   ```
   
   However, there is still an older version of `string_to_timestamp_nanos` that is in the datafusion codebase:
   https://github.com/apache/arrow-datafusion/blob/5900b4c6829b0bdbe69e1f95fb74e935bc8f33d4/datafusion/src/physical_plan/datetime_expressions.rs#L269
   
   **Expected behavior**
   datafusion should use the same function to convert between string -> timestamps in both places
   
   **Additional context**
   It appears the functions were moved in https://github.com/apache/arrow-rs/commit/db030cd4d21c7561b22da64173a8867c9be17fcd but did not quite clean up the datafusion implementation


-- 
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] alamb closed issue #766: Constant folding of to_timestamp uses different implementation than actual function call

Posted by GitBox <gi...@apache.org>.
alamb closed issue #766:
URL: https://github.com/apache/arrow-datafusion/issues/766


   


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