Sir,
I am concatenating 3 files using exec command stage like this
copy D:\Sequential_Files\CREATEHEADER + D:\Sequential_Files\CREATEDETAIL + D:\Sequential_Files\CREATETRAILER D:\Sequential_Files\BAH_HR_yyyymmdd.txt
but at the end of D:\Sequential_Files\BAH_HR_yyyymmdd.txt file i am
getting carriage return/line feed terminator.
Can you please help me out on how to remove line terminator.
Thanks
Reddy
How to remove carriage retrun from the last line of a file
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Why bother? If you are going to process all of this, simply add a constraint early in the job that skips that final empty line. Set your "missing field" properties appropriately.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Hi reddy,
I am not able to recreate your output exactly, but with the COPY command I do get a non-printable character of hex(1A) as the last character of the file.
I don't get this character if I use the /B option (binary file copy) with the COPY command. For example,
produces an output file with no extra characters at the end. Perhaps you can test the /B option.
katz
I am not able to recreate your output exactly, but with the COPY command I do get a non-printable character of hex(1A) as the last character of the file.
I don't get this character if I use the /B option (binary file copy) with the COPY command. For example,
Code: Select all
COPY /B file1.txt + file2.txt + file3.txt fileout.txt
katz