Hi everyone
My customer has given me a file downloaded from their banking Site which, on import, is read as one single row / line even though the file has 85 rows of data. I opened the file in different text file readers, textpad and notepad++ and notepad and it clearly has rows of data...
How can I split the line at every 40th character while reading it in?
Hope someone can help.
0
Answers
Don't process xml as a text file. Use an XMLPort or some Dotnet XML parser. XML does not need line breaks in order to mark-up records of a table.
Your XML-file, if it has line breaks indeed, probably uses Unix style line breaks (<LF> only, rather than windows standard <CR><LF>). An XML parser is required to convert line breaks to this format anyway, so, why not store it this way in the file in the first place.
Use a parser...
Hi Village_Idiot,
I see that you already resolved your problem. But If you want to resolve it properly, then:
1- Check your file with notepad++ (or equivalent). Show the special characters and see what is the return carriage on your file (CR, LF, CRLF ... or other)
3- Check "RecordSeparator" property on your XMLport and set it to the adequate value from your file (By default it equals <<NewLine>>).
The help says:
Thank you. You will notice in my very first post, I have written that I used notepad++ to check the file. and i did set record separators. Nothing worked until I set a limit on the record. It seems to work.