-
-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
number of fields in a row has to be based on the header #82
Comments
@mykhaylo- |
@doyaaaaaken thank you. |
@mykhaylo- |
To reproduce
Have a csv file with header row with 3 columns and two data rows, first data row with two columns, second - with three. Like this:
While invoking 'readAllWithHeaderAsSequence' on this file, the CSVFieldNumDifferentException is thrown saying that two colums are expected but three are found. It happens because 'fieldsNum' variable in the CsvFileReader.kt is initialized based on the first data row, while it has to be initialized based on the header row.
Expected behavior
The following code has to return two rows:
Environment
The text was updated successfully, but these errors were encountered: