Bug 123869 - import .csv with floats and delimiter=pipe is wrong
Summary: import .csv with floats and delimiter=pipe is wrong
Status: RESOLVED NOTABUG
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
6.0.7.3 release
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: CSV-Import
  Show dependency treegraph
 
Reported: 2019-03-05 11:30 UTC by Sinan Gabel
Modified: 2021-05-21 06:21 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments
.csv file (5.93 KB, image/png)
2019-03-05 14:22 UTC, Sinan Gabel
Details
.csv text import user screen (55.74 KB, image/png)
2019-03-05 14:23 UTC, Sinan Gabel
Details
.csv file imported into LibreOffice (67.91 KB, image/png)
2019-03-05 14:24 UTC, Sinan Gabel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sinan Gabel 2019-03-05 11:30:25 UTC
Description:
import .csv with floats and delimiter=pipe is wrong

Steps to Reproduce:
Import from .csv file e.g.:

1|0.0255|3.
2|0.0277|4.
3|0.025|5.


Actual Results:
1	0.0255	3.
2	0.0277	4.
3	25	5.


Expected Results:
1	0.0255	3.
2	0.0277	4.
3	0.025	5.



Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 Mike Kaganski 2019-03-05 11:51:14 UTC
Cannot reproduce with Version: 6.2.1.2 (x64)
Build ID: 7bcb35dc3024a62dea0caee87020152d1ee96e71
CPU threads: 12; OS: Windows 10.0; UI render: default; VCL: win; 
Locale: ru-RU (ru_RU); UI-Language: en-US
Calc: threaded
Comment 2 Eike Rathke 2019-03-05 11:58:25 UTC
Neither with
Version: 6.0.7.3.0+
Build ID: 806b1b1d91c1f9b2ca7d3121cffc5ea361e985ec
CPU threads: 8; OS: Linux 4.20; UI render: default; VCL: gtk3; 
Locale: en-US (en_US.UTF-8); Calc: group
Comment 3 Sinan Gabel 2019-03-05 12:17:46 UTC
I have:

Version: 6.0.7.3
Build ID: 1:6.0.7-0ubuntu0.18.04.2
CPU threads: 4; OS: Linux 4.15; UI render: default; VCL: gtk3; 
Locale: en-US (en_US.UTF-8); Calc: group
Comment 4 Mike Kaganski 2019-03-05 14:06:59 UTC
(In reply to Sinan Gabel from comment #3)

Possibly it could help to create a screencast.
Comment 5 Sinan Gabel 2019-03-05 14:22:06 UTC
Created attachment 149742 [details]
.csv file
Comment 6 Sinan Gabel 2019-03-05 14:23:34 UTC
Created attachment 149743 [details]
.csv text import user screen
Comment 7 Sinan Gabel 2019-03-05 14:24:28 UTC
Created attachment 149744 [details]
.csv file imported into LibreOffice
Comment 8 Mike Kaganski 2019-03-05 15:09:24 UTC
Confirmed with import settings from attachment 149743 [details] using Version: 6.2.1.2 (x64)
Build ID: 7bcb35dc3024a62dea0caee87020152d1ee96e71
CPU threads: 12; OS: Windows 10.0; UI render: default; VCL: win; 
Locale: ru-RU (ru_RU); UI-Language: en-US
Calc: threaded
Comment 9 kathwood 2020-06-06 04:30:17 UTC Comment hidden (spam)
Comment 10 Mike Kaganski 2021-05-21 06:21:43 UTC
Oh, but it is not a bug. The "problem" is that in the third row, the "0.025" is detected as a number 25; and that is correct, according to the "Danish" locale chosen in the "Language" selector (see tdf#138748 for the terminology issue). Danish locale uses dot as thousand separator; so the text where three decimal digits are separated by the dot are identified as integer values, and where different number of digits is separated by dot is correctly not detected as a valid number. The file does *not* use Danish locale conventions, so it should either be imported using English (USA) selected as "Language", or the column itself should be marked as "US English".