16.12.2012 Views

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

z/OS V1R9.0 UNIX System Services Command ... - Christian Grothoff

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Exit Values<br />

Portability<br />

Related Information<br />

sh, tcsh, true<br />

Because this command always succeeds, the only possible exit status is:<br />

0 Successful completion<br />

P<strong>OS</strong>IX.2, X/Open Portability Guide, <strong>UNIX</strong> systems.<br />

comm — Show and select or reject lines common to two files<br />

Format<br />

Description<br />

Options<br />

Localization<br />

Exit Values<br />

comm [–123] file1 file2<br />

comm locates identical lines within files sorted in the same collating sequence, and<br />

produces three columns; the first contains lines found only in the first file, the<br />

second lines only in the second file, and the third lines that are in both files.<br />

–1 Suppresses lines that appear only in file1<br />

–2 Suppresses lines that appear only in file2<br />

–3 Suppresses lines that appear both in file1 and file2<br />

The options suppress individual columns. Thus, to list only the lines common to<br />

both files, use:<br />

comm -12<br />

To find lines unique to one file or the other, use:<br />

comm -3<br />

Observe that comm -123 displays nothing.<br />

comm uses the following localization environment variables:<br />

v LANG<br />

v LC_ALL<br />

v LC_COLLATE<br />

v LC_CTYPE<br />

v LC_MESSAGES<br />

v NLSPATH<br />

See Appendix F for more information.<br />

: (colon)<br />

0 Successful completion<br />

1 Failure because of an error opening or reading an input file<br />

2 Failure that generated a usage message, such as naming only one input<br />

file<br />

Chapter 2. Shell command descriptions 141

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!