Skip to content

[R] mutate(x2=ifelse(x=='',NA,x)) Error: Function 'if_else' has no kernel matching input types  #33427

@asfimport

Description

@asfimport

 


q <- data.table(x=c('','30111976','01011976'))
q %>% write_dataset('q')
q2 <- 'q' %>% open_dataset %>% mutate(x2=ifelse(x=='',NA,x)) %>% collect
Error in `collect()`:
! NotImplemented: Function 'if_else' has no kernel matching input types (bool, bool, string)
Run `rlang::last_error()` to see where the error occurred.

In Functions available in Arrow dplyr queries it is stated that ifelse() is available, but the error above suggests otherwise.

Update, "str_replace" is another function that is supposedly available in 10.0.0 but is not (or does not seem to be):


q2 <- 'q' %>% open_dataset %>% mutate(x2=x %>% str_replace('',NA)) %>% collect
Error: Expression x %>% str_replace("", NA) not supported in Arrow
Call collect() first to pull data into R.

 

Reporter: Lucas Mation / @lucasmation
Assignee: Neal Richardson / @nealrichardson

Related issues:

Note: This issue was originally created as ARROW-18244. Please see the migration documentation for further details.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions