on 10-08-2015 12:41 PM
Hello,
I have on file to file scenario.
The file sender is nfs and file receiver is ftp.
I just want to move a txt file.
The file in the sender side has '0x0A' as end of file, but when it moves to the ftp server the end of file disappears and looks, everything in the same line.
Any ideas?
Thanks.
Finally I changed the scenario to proxy to SFTP and with the adapter XML2Plain
I could do everything I need.
localejbs/AF_Modules/MessageTransformBean
http://caihemm2.blog.163.com/blog/static/209765083201210522427135
Thanks to everyone.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Alejandro,
Are you using mode: append in receiver adapter..??
If Yes, then try to create file of type ".xls" rather ".txt". You will be able to see the required changes.
Regards,
Vishnu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Alejandro,
Try to use Transfer Mode Binary in your Sender and Receiver Channel.
Regards,
Diego
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You are using SFTP receiver and not FTP, and that's why there is no such option on the SFTP channel and therefore it will not work.
Before trying to fix this, have you tried viewing the file on Notepad++ to see if the contents are on one line or not? '0x0A' is a line feed (LF) character which most likely means that your sender system is on a Unix file system. If you view a file with a Unix EOL character on regular Notepad on Windows, it will all appear in the same line. This is because Windows EOL requires both carriage return (CR) and line feed (LF).
If you can see the content properly on Notepad++, the next question would be whether your target system requires just LF or CRLF. It could be that it just affects your viewing of the file on your laptop, but the target system can still process it correctly.
If you really need CRLF in the target system, then you can add the module SAP XI Sample/ConvertCRLFfromToLF to your SFTP receiver channel with the following parameter:
mode = any
Rgds
Eng Swee
Hi Eng,
I have tried your solution but it does not work. Probably I do something wrong.
I have change the end of the file origin to '0x0D''0x0A'
So the receiver that creates the file has this content conversion
Now in the scenario from file to SFTP, I write the module conversion that you said.
The file that is created in the SFTP receiver has CRLF and not LF only.
Any idea?
Thanks.
Alejandro
You haven't answered my questions above. Without answering them properly we might all be going on a wild goose chase.
Before trying to fix this, have you tried viewing the file on Notepad++ to see if the contents are on one line or not? '0x0A' is a line feed (LF) character which most likely means that your sender system is on a Unix file system. If you view a file with a Unix EOL character on regular Notepad on Windows, it will all appear in the same line. This is because Windows EOL requires both carriage return (CR) and line feed (LF).
If you can see the content properly on Notepad++, the next question would be whether your target system requires just LF or CRLF. It could be that it just affects your viewing of the file on your laptop, but the target system can still process it correctly.
Hello Alejandro,
you have used any File content conversion?
'0x0A'- Means new line.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The file in the sender side was created with another interface, with content conversion and on there was set the '0x0A' as the endSeparator.
The problem is when I want to move this file with the endSeparator '0x0A' to the file receiver.
For this scenario I don´t want to do any file content conversion, just move the file as it is in the sender side.
User | Count |
---|---|
93 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.