#1120 Export of SQL to file trimmed

3.4.0
open
nobody
None
5
2014-04-02
2013-12-18
No

Hi,

the export of a SQL result to file (csv, excel, maybe xml) is trimmed. When exporting data it is essential that the value ' 1234' is not identical to '1234'. It seems that in the source a String.trim() is done for every output written.

Discussion

  • sfst

    sfst - 2014-03-26

    Sometimes it even is practical. Can this be an export option?

     
  • Christian Hölzer

    I'm curious about your need for trimmed output, could you explain that further? I'm using it for export/import and especially key fields should not be trimmed as it is impossible to reimport the data.

     
  • sfst

    sfst - 2014-04-02

    In some databases all datafields were defined as NOT NULL, so when there isn't really any data a space is saved in those string fields. I export a lot into spreadsheets and finding any of those "blank" fields turns out to be easy because SQuirreL already trimmed them. I only import very little data compared to the volume I export.

    I agree that for keyfields it could be misleading, but in those databases I work with the keyfields are trimmed before saving.

    As I wrote, it is sometimes practical, not always, so having it as an option would allow both ways, but if I had to choose from one fixed implementaion I would prefer it untrimmed as well.

     

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks