Skip to content
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

Allow CSV imports to handle comma or tab separators #7664

Open
jmcameron opened this issue Jul 15, 2024 · 0 comments
Open

Allow CSV imports to handle comma or tab separators #7664

jmcameron opened this issue Jul 15, 2024 · 0 comments

Comments

@jmcameron
Copy link
Collaborator

By default, util.formatCsvToJson(file) parses for commas. However, Excel will generate "CSV" files with commas (for English-based locales), but will generate "CSV" files (by default) with tabs in French-based locals. This is very confusing to inexperienced Excel users in Congo who use Excel to edit/create CSV files.

The suggestion in this issue is to fix the problem by

  1. include a "Tab" or "Comma" checkbox on all import dialogs that are used to select files for importing CSV files, default it to comma, but allow the user to choose tabs. This will require modifying the utils.formatCsvToJson() function to accept an optional second argument for the desired delimiter.
  2. Add better error handling and an error message that explains the the user may need to convert tabs to commas in their input file (and first change commas to decimals).

Reference #4296

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant