Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


On 09/30/2012 10:02 AM, prino wrote:
I've got some data, that, very simplified looks like

1,2,3,4,"Cell E1"
2,2,3,4,"Cell E2"
3,2,3,4,""Cell E3""
4,2,3,4,"Cell E4"
5,2,3,4,""Cell E5""

i.e. it contains both text and quoted text.

When I import this (LO 3.6.1, W7-64, UK English) using

Codepage: System
Separated by: Comma
Merge delimiters: Yes (irrelevant)
Text delimiter: "

Quoted fields as text: Yes
Detect special numbers: Yes

line 4 of the input file ends up as the second line in cell E3 and the final
"CELL E5" (in cell E4) is followed by a newline

How do I get this imported correctly - any solutions that suggest to modify
the input data are unacceptable, the data comes from z/OS and for what it's
worth, imported correctly in LO 3.5.4...
The problem is that the data is not properly formatted. Row 3 and row 5 is where you have an extra pair of double quotes. This is your problem. Remove the extra quotes, and you also remove the problem. To properly format a CVS file, only a number or text exists between commas. This is also true for what appears after the last comma of a row. The data above violates this formatting, and this is the reason for the problems. And for the record, opening a CVS file containing this data using LO 3.4.6 or 3.5.6 does not import correctly: it only appears to do so. Row 3 col 5 has Cell E3"" which is not the same as Cell E3. Row 5 col 5 has Cell E5"" not Cell E5.

--Dan


--
For unsubscribe instructions e-mail to: users+help@global.libreoffice.org
Problems? http://www.libreoffice.org/get-help/mailing-lists/how-to-unsubscribe/
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/global/users/
All messages sent to this list will be publicly archived and cannot be deleted

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.