Skip to main content

Export to CSV chopping off leading zeroes

Comments

5 comments

  • Permanently deleted user

    Update: this is also happening in the current version of Essentials.

    0
  • Nico Burgerhart

    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
  • Permanently deleted user

    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
  • Permanently deleted user

    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 Partner 
    0
  • Permanently deleted user

    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

Please sign in to leave a comment.