Ali Khanafer wrote: > Thanks Eric and Bob. I had sorted the files before calling comm, but I > think the problem is that I sorted them as numeric: > > sort -n test1 -o test1 > > When I removed the "-n", which is equivalent to what Bob has done, comm > worked like a charm.
Yes that would cause the problem. comm is a simple program from years and years ago and expects things to be sorted simply. Sort options in the various programs have come up for discussion every so often. But so far things have continued as they are. The biggest changes in this area have been having the tools produce diagnostic information when the input is not as they expect. Check out the sort --debug option for more useful diagnostics about sorting. Glad things have been /sorted/ out! :-) Bob
