Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?

It seems we need to wait ARROW-3543 for preserving timezones.

library(arrow)
#> 
#> Attaching package: 'arrow'
#> The following object is masked from 'package:utils':
#> 
#>     timestamp

jst <- lubridate::now()
utc <- lubridate::with_tz(jst, "UTC")
d <- tibble::tibble(jst = jst, utc = utc)

d
#> # A tibble: 1 x 2
#>   jst                 utc                
#>   <dttm>              <dttm>             
#> 1 2019-12-09 18:46:18 2019-12-09 09:46:18

tmp <- tempfile()

write_parquet(d, tmp)

d <- read_parquet(tmp)

d$jst
#> [1] "2019-12-09 18:46:18 JST"
d$utc
#> [1] "2019-12-09 18:46:18 JST"

Created on 2019-12-09 by the reprex package (v0.3.0)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.