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/11/07 18:58:37 UTC

[GitHub] [arrow-rs] alamb opened a new issue, #3042: Improved UX of creating `TimestampNanosecondArray` with timezones

alamb opened a new issue, #3042:
URL: https://github.com/apache/arrow-rs/issues/3042

   **Is your feature request related to a problem or challenge? Please describe what you are trying to do.**
   While working on https://github.com/apache/arrow-datafusion/pull/4039 and https://github.com/influxdata/influxdb_iox/pull/6061 I ended up having to do this many times:
   
   ```rust
   Arc::new(TimestampNanosecondArray::from(vec![...],)
     .with_timezone("+0:00".into())
   ```
   
   While this API is already nicer than previously, there are two more improvements that might help:
   
   **Describe the solution you'd like**
   Allow passing `&str` as well as `String` to `with_timezone`:
   
   ```rust
   Arc::new(TimestampNanosecondArray::from(vec![...],)
     .with_timezone("+0:00")
   ```
   
   Add an alias for UTC:
   ```rust
   Arc::new(TimestampNanosecondArray::from(vec![...],)
     .with_timezone_utc()
   ```
   
   
   **Describe alternatives you've considered**
   <!--
   A clear and concise description of any alternative solutions or features you've considered.
   -->
   
   **Additional context**
   cc @waitingkuo  who is actively working to improve the timezone situation in arrow / datafusion ❤️ 
   
   I think this is a good first issue as the code and tests are already there, all that is needed is a signature change (from `String` to `impl Into<String>`) and some tests


-- 
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-rs] waitingkuo commented on issue #3042: Improved UX of creating `TimestampNanosecondArray` with timezones

Posted by GitBox <gi...@apache.org>.
waitingkuo commented on issue #3042:
URL: https://github.com/apache/arrow-rs/issues/3042#issuecomment-1307752467

   i'll take it if there's no one take it this week or next.
   if there's anyone interested in, i happy to point out the codes to modify


-- 
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-rs] waitingkuo commented on issue #3042: Improved UX of creating `TimestampNanosecondArray` with timezones

Posted by GitBox <gi...@apache.org>.
waitingkuo commented on issue #3042:
URL: https://github.com/apache/arrow-rs/issues/3042#issuecomment-1308335398

   @src255 
   you could add the `with_timezone_utc()` here
   https://github.com/apache/arrow-rs/blob/master/arrow-array/src/array/primitive_array.rs#L762-L797
   
   and follow this to add a test case
   https://github.com/apache/arrow-rs/blob/master/arrow-array/src/array/primitive_array.rs#L1340-L1353


-- 
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-rs] tustvold closed issue #3042: Improved UX of creating `TimestampNanosecondArray` with timezones

Posted by GitBox <gi...@apache.org>.
tustvold closed issue #3042: Improved UX of  creating `TimestampNanosecondArray` with timezones
URL: https://github.com/apache/arrow-rs/issues/3042


-- 
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-rs] src255 commented on issue #3042: Improved UX of creating `TimestampNanosecondArray` with timezones

Posted by GitBox <gi...@apache.org>.
src255 commented on issue #3042:
URL: https://github.com/apache/arrow-rs/issues/3042#issuecomment-1307978836

   @waitingkuo I can help with this. Which file(s) should I modify? 


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