Issue 112060 - Opening and saving a CSV looses decimal precision without warning
Summary: Opening and saving a CSV looses decimal precision without warning
Status: CONFIRMED
Alias: None
Product: Calc
Classification: Application
Component: save-export (show other issues)
Version: OOo 3.2
Hardware: Mac All
: P3 Normal (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-03 07:29 UTC by katzlbt
Modified: 2013-04-03 15:38 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: 3.4.1
Developer Difficulty: Medium


Attachments
Sample CSV with geographic coordinates to open and close (79 bytes, text/plain)
2010-06-03 07:33 UTC, katzlbt
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description katzlbt 2010-06-03 07:29:21 UTC
1. Open sample.csv containing geographic coordinates:
"location",47.1278193378553,10.2723455429077,10.2658760547638,47.1259816505082
2. Modify "location"
3. Save the CSV with the save button for database import into an external system
(this causes data-loss):
"My Location",47.12,10.27,10.26,47.12

There is abolutely no warning and no way to prevent this data loss. 

Telling users to *PLEASE not forget* to use "Save as ..." CSV function and not
to forget to check the "modify filters" setting and not to forget to set "UTF-8
format" and not to forget to uncheck "save as shown" is way to complicated for
simple minds.
Comment 1 katzlbt 2010-06-03 07:33:31 UTC
Created attachment 69773 [details]
Sample CSV with geographic coordinates to open and close
Comment 2 Regina Henschel 2010-06-03 13:40:50 UTC
What is this issue about? You know already issue 68636 for setting "uncheck" as
default to Checkbox "Save cell contents as shown".
Comment 3 katzlbt 2010-06-13 12:15:55 UTC
This issue is about opening and saving a document in CSV Format (processing a
file). This will modify data without the user being able to detect and/or
prevent that until it is too late. As a user I expect a save operation to save
my data as accurate as possible, so I can open and modify it again later. In the
case of opening a CSV file data is imported with 2 decimal digits shown and
saving it in the same format, OO does not show the export dialogue.

Possible fixes:
a) Show all decimal digits when importing a CSV by using a sensible Cell Format.
b) Save data as stored, not as shown.

I do not know a usecase where the truncation of decimal places is desirable when
saving in CSV format. I would be glad to know a usecase that supports the
truncation functionality.

The issue is related to 68636 as the issues have the same outcome (data loss),
but they are not identical. 68636 is about "exporting a CSV". This issue is
about the usecase "processing a file in CSV format". 68636 should be closed, as
it is in the "NEW" state for 4 years. 68636 does not have CSV in the title, so I
did not find it by searching.
Comment 4 Rob Weir 2013-02-02 02:54:45 UTC
This Issue requires more information ('needmoreinfo'), but has not been updated
within the last year. Please provide feedback as requested and re-test with the the latest version of OpenOffice - the problem(s) may already be addressed. 

You can download Apache OpenOffice 3.4.1 from http://www.openoffice.org/download

Please report back the outcome of your testing, so this Issue may be closed or
progressed as necessary - otherwise the issue may be Resolved as Invalid in the
future.
Comment 5 Rob Weir 2013-04-03 15:38:29 UTC
Tested with AOO 3.4.1 on Windows 7 64-bit.

Input CSV file, from the attachment to the issue, has digits with 15 significant digits.  This should fit, without loss, in an IEEE double.  Saving the file back from within Calc gives on 12 significant digits.

For example:

Original:  47.1278193378553

Resaved:  47.1278193379

However, I don't see the two-decimal truncation reported by katzlbt.