| Issue 13: | readHeader() doesn't parse the comma separated header fields | |
| 1 person starred this issue and may be notified of changes. | Back to list |
What steps will reproduce the problem? 1. call CsvReader.readHeader() 2. 3. What is the expected output? What do you see instead? I expect the List<String> will contain a list of headers for each comma separated field. Instead it gives the entire line, unparsed. I would have to write a csv parser myself to parse the header line. Useless. What version of the product are you using? On what operating system? 1.4.0 on JDK 1.7 on Windows 7 enterprise. Please provide any additional information below. |
I think this is because the default Strategy has a semi-colon as the delimiter, not a comma. You'll have to create a [ new Strategy(',', '"', '#', false, true) ]. The only difference between this listed one and the default is the ; changed to a , which might fix the problem. Since it's looking for a ; to split the header and finds none, it assumes you have only 1 column overall.