voltrondata / substrait-r

An R Interface to the 'Substrait' Cross-Language Serialization for Relational Algebra
Other
27 stars 7 forks source link

Error when selecting date columns #265

Closed thisisnic closed 1 year ago

thisisnic commented 1 year ago
library(substrait)
#> 
#> Attaching package: 'substrait'
#> The following object is masked from 'package:stats':
#> 
#>     filter
library(dplyr)
#> 
#> Attaching package: 'dplyr'
#> The following objects are masked from 'package:stats':
#> 
#>     filter, lag
#> The following objects are masked from 'package:base':
#> 
#>     intersect, setdiff, setequal, union
tibble::tibble(x = as.Date("1987-10-09")) %>%
  arrow_substrait_compiler() %>%
  select(x)
#> Error in from_substrait.vctrs_unspecified(dots[[1L]][[1L]], dots[[2L]][[1L]]): Can't convert substrait.Type<date> to ptype<any>

tibble::tibble(x = as.Date("1987-10-09")) %>%
  duckdb_substrait_compiler() %>%
  select(x)
#> Error in from_substrait.vctrs_unspecified(dots[[1L]][[1L]], dots[[2L]][[1L]]): Can't convert substrait.Type<date> to ptype<any>

Created on 2023-03-28 with reprex v2.0.2