Skip to content

[R] Better messaging for currently unsupported CSV options in open_dataset #26439

@asfimport

Description

@asfimport

While read_csv_arrow()'s signature matches readr,  the readr_to_csv_parse_options() function (called by way of open_dataset()) only appears to capture a subset of those options:

(

arrow/r/R/csv.R

Line 464 in 883eb57

delimiter = delim,
)

readr_to_csv_parse_options <- function(delim = ",",
 quote = '"',
 escape_double = TRUE,
 escape_backslash = FALSE,
 skip_empty_rows = TRUE)

I ran into this trying to use a non-standard 'na' value:

 

open_dataset("/path/to/csv/directory/", schema = sch, partitioning=NULL, format="csv", delim=";", na="\\N", escape_backslash=TRUE, escape_double=FALSE`)
Error in readr_to_csv_parse_options(...) : unused argument (na = "\\N")

 

Reporter: Gabriel Bassett
Assignee: Ian Cook / @ianmcook

Related issues:

PRs and other links:

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

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions