Menu

flat2xml CSV tab delimited

Help
Anonymous
2004-07-23
2004-08-12
  • Anonymous

    Anonymous - 2004-07-23

    I have a simple question:
    How do I config tab as a delimiter in the <field-separator></field-separator> Tag?
    I tryed :
    <field-separator><![CDATA[&#9;]]></field-separator>
    <field-separator><![CDATA[&#x9;]]></field-separator>
    <field-separator>\t</field-separator>
    <field-separator>  </field-separator> (tab inside the tag)
    <field-separator>&#9;</field-separator>

    Until now, nothing worked.

    Thanks,

    Paul

     
    • bruce mcdonald

      bruce mcdonald - 2004-07-24

      Hmmm...  I don't know.  Can you place some kind of debug statement in the java class:

      com.babeldoc.conversion.flatfile.FlatFileConverter

      line 190.   Print the separator...

       
      • Mitch Christensen

        Back in December (2003) we had a similar dilemma.  In a nutshell, the flat2xml stage doesn't support tab delimited text.  I had to modify the Babeldoc source myself and rebuild Babeldoc.  I posted my solution back then in the hopes that it would get incorporated back into CVS (and it apparently hasn't). 

        You can see my solution at:

        https://sourceforge.net/forum/forum.php?thread_id=992723&forum_id=190909

        I hope this helps.

        -Mitch

        FWIW, is anyone interested in incorporating this simple fix back into the Babeldoc code?  I'm sure others might be interested in processing tab-delimited text.

         
    • bruce mcdonald

      bruce mcdonald - 2004-07-28

      This fix is in the code base....  

      Paul:  try the example that Mitch gives:

      &lt;field-separator&gt;\t&lt;/field-separator&gt;

      If that does not work - do the println, and let me
      know how that goes.

       
    • Anonymous

      Anonymous - 2004-08-12

      Sorry the delay, I was away for a couple of days...

      Yes, this works fine now.
      Thank you very much for your help!

      And yes, I used the src-release 1.2.1 and not the code base. So thats why the fix was not in the source.

      Again: Thanks!

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.