Operating System - OpenVMS
1753336 Members
4694 Online
108792 Solutions
New Discussion юеВ

Re: Appending Binary Files

 
Susan Clark
New Member

Appending Binary Files

I have a user who wants to append one binary file to another, but does not want the zeros at the end of each file listed. Is this possible? If so what is the correct command?
4 REPLIES 4
RBrown_1
Trusted Contributor

Re: Appending Binary Files


The command to append file A to the end of file B is

$ APPEND A B

"Binary file" is a meaningless term in the VMS world, and perhaps elsewhere.

$ DIRECTORY/FULL of the files in question would at least let us know what you are talking about. $ ANALYZE/RMS would be even better.

"does not want the zeros at the end of each file listed". ??? The append operation does not do any listing. Do you mean that the user does not want the data at the end of the files included in the resultant file?

If you want to remove data from a file, you will need some kind of a filter. For a first try, I would use an editor.

Good luck.
Jon Pinkley
Honored Contributor

Re: Appending Binary Files

Please tell us what you mean by "Binary file".

What does

$ dump/header/block=(count:0) filename

show for the file?

By "the zeros at the end of each file" do you mean bytes that are past the end of file mark?

Jon
it depends
Hoff
Honored Contributor

Re: Appending Binary Files

Possible? Sure. Trivial.

The direct and literal approach here is unlikely to have the desired results, however.

As an example of this, directly jamming together two Microsoft Word documents - which are binary files, for the sake of this discussion - won't work.

Please tell us what problem or task the user is seeking to perform here, and not how the user proposes to solve it.

This includes background on the problem and the goals, and details on the particular binary file format(s) and application programs involved.
Andy Bustamante
Honored Contributor

Re: Appending Binary Files

>>>Appending Binary Files

If you're referring to data files you should review the sort merge utility in the OpenVMS Users Manual. See chapter 9 http://h71000.www7.hp.com/doc/731final/6489/6489pro_020.html#sort_ch

Andy
If you don't have time to do it right, when will you have time to do it over? Reach me at first_name + "." + last_name at sysmanager net