Link to home
Start Free TrialLog in
Avatar of CipherIS
CipherISFlag for United States of America

asked on

FTP Convert binary file to ASCII

I am uploading a file.  User needs the file in ASCII format.  Whenever I upload I receive the below error.

550-RMS WRITE RTB record too large.
550 !UL byte record too large for user's buffer

If I upload in Binary there is no error.

Is there a way to upload or convert the file in its location to ASCII?

Thanks
Avatar of Paul MacDonald
Paul MacDonald
Flag of United States of America image

BIN and ASCII are just transfer modes.  They have no effect on the file itself.  In other words, if you transmit in Binary, the user can still open the file just fine.
Avatar of CipherIS

ASKER

Unfortunately there is a process that is trying to pick up the file and it needs it in ASCII.
That all depends if you know how it was place in binary format. For example a native executable is a binary file but you can not just convert it to ASCII. If you were to serialize a object in C#/VB .Net to a binary format into a file you could not just apply some template to convert it to ASCII you would need to use the same object model to deserialize it back to the object in a program.

So do you know how the binary file was created?
Avatar of ☠ MASQ ☠
☠ MASQ ☠

Which client are you using?
In FileZilla there's a menu option but also a quick select at the bottom of the screen when you are connected to the server
User generated imageUser generated image
You don't understand Binary mode will work for any type of data.  You simply cannot go wrong transferring the data in Binary mode.  It will not magically change your ASCII text file into a GIF or something.  

Seriously.  Give it a try.
http://www-05.ibm.com/de/support/ecurep/send_ftp.html

"When files are transferred in ASCII mode, the transferred data is considered to contain only ASCII formatted text. The party that is receiving the transferred data is responsible for translating the format of the received text to one that is compatible with their operating system. The most common example of how this is applied pertains to the way Windows and UNIX handle newlines. On a Windows computer, pressing the "enter" key inserts two characters in an ASCII text document - a carriage return (which places the cursor at the beginning of the line) and a line feed (which places the cursor on the line below the current one). On UNIX systems, only a line feed is used. ASCII text formatted for use on UNIX systems does not display properly when viewed on a Windows system and vice versa.

Binary mode refers to transferring files as a binary stream of data. Where ASCII mode may use special control characters to format data, binary mode transmits the raw bytes of the file being transferred. In binary mode, the file is transferred in its exact original form."
@paulmacd we have tried it in Binary and the system has to be reset.
What is in the file before the transfer, and what do you want the file to contain after the transfer?
Just needed in ASCII format.  Unsure what the file is before the transfer.
What do you mean by "ASCII format"?
Do you want to remove all characters that are not in the range \0 - \177 ?
Could you manage to post here the same file in both formats?

As pointed above:
- this ASCII/bin thing is just an option in your ftp client (which one do you use?
- if there are differences, and unless you have selected (probably unwantedly) some verys strange option, the only possible differences should be in the end-of-line area

- another explanation to your problem might be the program you are using after the transfer: it might search for a very precise string of bytes, and shout "binary! binary" as soon as it does not find them. can you give us more information on this program?
ASKER CERTIFIED SOLUTION
Avatar of sarabande
sarabande
Flag of Luxembourg image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial