Adding a line feed to each line

Hi folks,

I did a search on this and didn't really find what fit my needs. I have a file with fixed record length of 436 bytes. I want to add a line feed x"0A" to the end x"0A" of each record(in byte 437). What's the easiest way to accomplish this?

Thanks.

awk '{print $0"\x0a"}' file > outfile
fold -w 436 file

I don't think the solution is that simple. As I read it the file consists of one record containing 436* number_of_logical_records characters.
Referring to post #2

I get an error message "awk: record `0000000007654592010-...' too long", which is referring to the first record in the file.

There are several thousand records in this file(when viewed in a file editor where the record length can be defined). However when opened in Notepad, etc it looks like one long record. If I understand the above, it looks like it is adding one line feed at the end of the file, since it would appear to be one long record.

Don't know what Operating System you have, but the general solution is to use the "dd" command.

Syntax can vary (see "man dd") but for example:

dd if=input_filename of=output_filename cbs=437 conv=unblock