I'm looking for sample code that merges two files. Code or location
would be appreciated.
Thanks,
Alan
--
Ratheon/E-Systems
7700 Arlington Boulevard
Falls Church, VA 22046
I'm looking for sample code that merges two files. Code or location
would be appreciated.
Thanks,
Alan
--
Ratheon/E-Systems
7700 Arlington Boulevard
Falls Church, VA 22046
> I'm looking for sample code that merges two files. Code or location
> would be appreciated.
could you be a little more specific?
I mean 'cat file1 file2 > file3' will merge two files, but that
is probably not what you mean. :)
cliff
void (FILE* OutFile, FILE* In1, File* In2)
{ int c;
while ( (c = getc(In1)) != EOF )
putc(c, OutFile);
while ( (c = getc(In2)) != EOF )
putc(c, OutFile);
}
If you're talking about scripting, use:
cat file1 file2 >outfile
If you're talking merge-sort, try:
cat file1 file2 | sort >outfile
--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Sean Walton, KB7rfa (Tech+) [name mangled: "swalton" is username]
Intelligent Algorithmic Solutions (IAS)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> I'm looking for sample code that merges two files. Code or location
> would be appreciated.
> Thanks,
> Alan
> --
> Ratheon/E-Systems
> 7700 Arlington Boulevard
> Falls Church, VA 22046
1. How to merge two columns of numbers from two different files?
Hi there:
I have two data files which have more than a few columns of numbers.
I want to pick certain column from each file and merge them together into a
third file. How to do this? Too bad awk only takes one input file
Regards
2. windows <-> linux PPP management
3. Looking for "diff"-like code to find differences between two files
5. looking for "c" sample code for modem I/O
7. Help - looking for sample code of char drivers with r/w buffers
9. Looking for sample code using isdnio.h, ISDN BRI card under Sun Solaris
10. Looking for a sample of code using TLE
11. Looking for some RPC sample code
12. Looking for portable libelf sample code
13. Help - looking for daemon sample code and document