Export to CSV chopping off leading zeroes
I have a client who is running GE 3.15/SLV 1.10. We're finding that when they make a feature selection and export it to CSV, the resulting file is missing the leading zeroes when all characters are numbers. If there is a letter in the field, the value is exported correctly. Is this a known issue that is fixed in a later release? I'd appreciate any information about this.
Dave
-
Update: this is also happening in the current version of Essentials.
0 -
An alternative is building a custom export to csv functionality with a workflow.
In the workflow you can modify (and reformat) the data in the datatable.
0 -
Thank you Nico. I thought about that too, and that would definitely be a feasible alternative. I just believe that this is an oversight on Latitude's part and should be corrected in the product.
0 -
Hi David,
Please open the file using a plain text editor such as notepad to ensure the zeros are in fact missing. Excel removes leading zeros when it believes the cell is a number, if you were looking at the file using Excel it could be the cause. The zeros may be in the file, you are just not being shown them.
Regards,
Wayne Richard Latitude Geographics Group Ltd. Head Office: 200 – 1117 Wharf Street Victoria, BC Canada V8W 1T7 Tel: (250) 381-8130 | Fax: (250) 381-8132 | wrichard@latitudegeo.com Developers of Geocortex web-based mapping software | www.geocortex.com An Esri Platinum Business Partner0 -
Thanks Wayne, you were correct. The CSV file is being correctly generated, but it's not interpreted correctly by Excel, even after you change the column's format to text. Here's a workaround I found on a Microsoft forum:
1. Open a blank Excel Spreadsheet.
2. Click on "Data->From Text"
3. At the bottom of the "Select Data Source" window, from the "Files of Type" dropdown, Select "Text Files (*.txt, *.prn, *.CSV.. etc)" and Copy and Paste the .Csv file name with complete Path.
4. Choose the file type as "Delimitted"
5. Choose Comma as the Delimiter
6. In "Step 3", select the column that should retain the zeroes and choose "Text" from the "Column Data Format" section.
7. Click on Finish.
0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
5 Kommentare