You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
While FastCSV automatically detects different line delimiters (CR, LF and CRLF) and also provides a way to automatically detect BOM headers, it's currently unable to automatically detect the character used as a field separator.
It's a common problem that CSV files are not always saved with the same field separator. For example, some files use a comma (which would be the only valid separator according to the RFC), while others use a semicolon or something else. This can lead to parsing errors or incorrect data being read.
The idea is to implement a feature that automatically detects the field separator based on the content of the CSV file. This could be done by analyzing the first few lines of the file and counting the occurrences of different potential field separators. The one with the highest count would be chosen as the field separator.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
While FastCSV automatically detects different line delimiters (CR, LF and CRLF) and also provides a way to automatically detect BOM headers, it's currently unable to automatically detect the character used as a field separator.
It's a common problem that CSV files are not always saved with the same field separator. For example, some files use a comma (which would be the only valid separator according to the RFC), while others use a semicolon or something else. This can lead to parsing errors or incorrect data being read.
The idea is to implement a feature that automatically detects the field separator based on the content of the CSV file. This could be done by analyzing the first few lines of the file and counting the occurrences of different potential field separators. The one with the highest count would be chosen as the field separator.
Beta Was this translation helpful? Give feedback.
All reactions