flink-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Malte Schwarzer ...@mieo.de>
Subject Quotes in fields of CsvInputFormat
Date Fri, 05 Dec 2014 15:16:56 GMT
Hi,

I¹m try to import a CSV file but the parser seems to have problems this
quotes in the beginning of a field. Is there a way to set or disable
enclosures for the CSV input?

This is my  code:

DataSet<Tuple2<String, String>> res = env.readCsvFile(inputCsvFilename)
                .fieldDelimiter('|')
                .types(String.class, String.class)

CSV:

A|ggg
B|"hhh" xx
C|xxx

As result I¹m receiving a ParserException for line B:

org.apache.flink.api.common.io.ParseException: Line could not be parsed:
'B|"hhh" xxŒ


Thanks,
Malte



Mime
View raw message