You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@arrow.apache.org by "Dariush Eivazi (Jira)" <ji...@apache.org> on 2022/05/16 12:26:00 UTC
[jira] [Created] (ARROW-16586) C++ CSV Reader Does not remove BOM
Dariush Eivazi created ARROW-16586:
--------------------------------------
Summary: C++ CSV Reader Does not remove BOM
Key: ARROW-16586
URL: https://issues.apache.org/jira/browse/ARROW-16586
Project: Apache Arrow
Issue Type: Bug
Components: C++
Affects Versions: 7.0.0
Reporter: Dariush Eivazi
Attachments: IRO3Z0360009.csv
h1. C++ CSV Reader Does not remove BOM
This is a repeat! of issue ARROW-5413 which is marked as RESOLVED.
When trying to read a csv file according to instruction given on [https://arrow.apache.org/docs/cpp/csv.html,] the library fails to read a CSV file containing utf8 strings starting with BOM. I attached the BAD file!.
the Code I trying to use is:
{code:java}
ARROW_ASSIGN_OR_RAISE(auto input, arrow::io::ReadableFile::Open(csv_filespec.string()));
auto io_context = arrow::io::default_io_context();
auto read_options = arrow::csv::ReadOptions::Defaults();
auto parse_options = arrow::csv::ParseOptions::Defaults();
auto convert_options = arrow::csv::ConvertOptions::Defaults();
// Set column names & types
read_options.column_names = column_names;
convert_options.column_types = column_types;
// Instantiate TableReader from input stream and options
RROW_ASSIGN_OR_RAISE(
auto reader, arrow::csv::TableReader::Make(io_context, input, read_options, parse_options, convert_options));
ARROW_ASSIGN_OR_RAISE(auto table, reader->Read()); {code}
Am I missing some thing or the issue 5413 still exists?
--
This message was sent by Atlassian Jira
(v8.20.7#820007)