Removing Carriage return to create one record

I have a file with multiple records in it and want to create a single record by removing all the carriage returns, is there a sed command or another command that will easily allow this to happen.

current layout
813209A
813273C
812272B

expected result
813209A813273C812272B

previously I outputted it as an array and then removed the spaces but record count will be close to 127 mil and I have a feeling we will exceed our LINE_MAX.

HP-UX

Thanks
B

Reminder: the site rules require that you search the site before posting a question...

Removing carriage return characters from file

127 million? Seems like that could cause some problems...

Try awk '{printf $1}' your_file

------
well this is one way anyway :slight_smile:

Thanks for the help, I will remember to search next time