Hitachi Vantara Pentaho Community Forums
Results 1 to 9 of 9

Thread: Is this a bug? - Text file output line split

  1. #1
    Join Date
    Jan 2018
    Posts
    8

    Default Is this a bug? - Text file output line split

    Hi,

    I have a transformation file that is for some reason splitting and creating a new line from a description in a file. It splits mid word as opposed to something like a , or a ;. I cannot use a , as my delimiter as there are other descriptions that have ,'s in them. I am using a ; but this word does not include one. Attaching pictures of the line straight out of the database, my text file output properties, and how it looks in the final file.

  2. #2
    Join Date
    Jan 2018
    Posts
    8

    Default

    cant post attachments.

    Basically, there is a word in the databse "MAINTENANCESEAL FL". In my file it keeps splitting at the end of the word maintenance and creating a new line. I am putting this into a text file output.

  3. #3
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    You are producing a CSV file using Text-File-Output and there is a linebreak where none should be?
    Either the linebreak is part of the field value that comes from the database, or it's just a presentational thing.

    How did you assert there's no linebreak in that field value?
    So long, and thanks for all the fish.

  4. #4
    Join Date
    Jan 2018
    Posts
    8

    Default

    Quote Originally Posted by marabu View Post
    You are producing a CSV file using Text-File-Output and there is a linebreak where none should be?
    Either the linebreak is part of the field value that comes from the database, or it's just a presentational thing.

    How did you assert there's no linebreak in that field value?
    It is breaking within the word itself. There is no space.

  5. #5
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    My question was: How did you assert there's no linebreak in that field value?

    Just because you don't see it, it still could be there.




  6. #6
    Join Date
    Jan 2018
    Posts
    8

    Default

    Quote Originally Posted by marabu View Post
    My question was: How did you assert there's no linebreak in that field value?

    Just because you don't see it, it still could be there.



    Ah good point. I did not really assert that there was then. Not sure how I would. Possibly using a different file format?

  7. #7
    Join Date
    Jun 2012
    Posts
    5,534

    Default

    You could use a Calculator step to create a hexadecimal representation of the field value.
    On the other hand, you could use an Editor capable of showing control characters (e.g. Notepad++) to make sure it's not a "soft return" due to oversized lines.

  8. #8
    Join Date
    Jan 2018
    Posts
    8

    Default

    Quote Originally Posted by marabu View Post
    You could use a Calculator step to create a hexadecimal representation of the field value.
    On the other hand, you could use an Editor capable of showing control characters (e.g. Notepad++) to make sure it's not a "soft return" due to oversized lines.
    I put it through a text editor and it says LF at the end of the line where it splits.

  9. #9
    Join Date
    Jan 2018
    Posts
    8

    Default

    Quote Originally Posted by marabu View Post
    You could use a Calculator step to create a hexadecimal representation of the field value.
    On the other hand, you could use an Editor capable of showing control characters (e.g. Notepad++) to make sure it's not a "soft return" due to oversized lines.
    I got it working AND appreciate your help on this! Your question helped point me in the right direction. I was able to ignore the LF control characters. Found out this was happening when """" """"""" was around a word. I had to use enclosures to fix this as well.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2017 Pentaho Corporation. All Rights Reserved.