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

Save as CSV is not separated by commas #352

Closed
alvarengasv opened this issue Nov 20, 2015 · 8 comments
Closed

Save as CSV is not separated by commas #352

alvarengasv opened this issue Nov 20, 2015 · 8 comments

Comments

@alvarengasv
Copy link

The CSV file is actually separated by semicolon. If you open in excel the whole line is in a single column.
If you edit in notepad and replace all ; with , it opens correctly in excel.

@gpproton
Copy link

This is also a major issue for me as i normally create analysis with excel files, i would love if the CVS files are displayed properly, i hope this is fixed soon.

Omonluimhen Godwin Peter

IT/Tracking
Officer | Beta Bridges Ltd

Date: Fri, 20 Nov 2015 04:48:38 -0800
From: [email protected]
To: [email protected]
Subject: [traccar-web] Save as CSV is not separated by commas (#352)

The CSV file is actually separated by semicolon. If you open in excel the whole line is in a single column.

If you edit in notepad and replace all ; with , it opens correctly in excel.


Reply to this email directly or view it on GitHub.

@vitalidze
Copy link
Owner

The separator is actually locale-dependent because for example comma may be treated as decimal separator. Thus, I believe using ';' separator always is a more universal solution See this for more info: https://en.wikipedia.org/wiki/Comma-separated_values

You can try the solution from here: http://superuser.com/questions/180964/how-to-open-semicolon-delimited-csv-files-in-us-version-of-excel (like add sep=; at the beginning or rename file to .txt and then import it).

@alvarengasv
Copy link
Author

Each of the column values are inside quotes so using comma as a column separator doesn't affect the comma when used as decimal separator. This will show up as 2 columns in excel not 3:
"13,50","50,75"

@vitalidze
Copy link
Owner

Most probably I will end with putting 'sep=;' at the beginning of output file.

vitalidze added a commit that referenced this issue Nov 22, 2015
… separator symbol at the beginning of file with 'sep=' line
@vitalidze
Copy link
Owner

I have made the following changes:

  1. Field separator is now set up depending on current user's language/locale of the web UI. If locale uses ',' as the decimal separator then ';' will be used as field separator, ',' is used in all other cases.

  2. At the beginning of the CSV file there will be a line indicating the field separator used for the whole file (sep=; or sep=,)

I believe this should cover all cases. I have checked it in MS Excel 2010 and it works just fine.

This is not yet included in the public available release, but it will be included in next version coming next week.

@gpproton
Copy link

Hi Litvak

I think it would be great to make reports open in a new tab and also be able to export the report to CSV file format.

Godwin Peter .O
IT /Tracking Officer | Beta Bridges Ltd
[email protected]
+2348083353682


From: Vitaly Litvakmailto:[email protected]
Sent: ‎11/‎22/‎2015 9:33
To: vitalidze/traccar-webmailto:[email protected]
Cc: gpprotonmailto:[email protected]
Subject: Re: [traccar-web] Save as CSV is not separated by commas (#352)

I have made the following changes:

  1. Field separator is now set up depending on current user's language/locale of the web UI. If locale uses ',' as the decimal separator then ';' will be used as field separator, ',' is used in all other cases.

  2. At the beginning of the CSV file there will be a line indicating the field separator used for the whole file (sep=; or sep=,)

I believe this should cover all cases. I have checked it in MS Excel 2010 and it works just fine.

This is not yet included in the public available release, but it will be included in next version coming next week.


Reply to this email directly or view it on GitHub:
#352 (comment)

@vitalidze
Copy link
Owner

In future probably it will be possible to export reports to different formats: HTML (now implemented), XLS and PDF. As for opening in new tab, it is already implemented, there will be a 'preview' check box in the report profile. Will be included in next version.

Please don't post any further questions related with reports in this thread because it is related with exporting of archive data to CSV.

vitalidze added a commit that referenced this issue Nov 24, 2015
@vitalidze
Copy link
Owner

Implemented, written news, updated latest and demo versions.

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

No branches or pull requests

3 participants