Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!samsung!munnari.oz.au!metro!wolfen!hls0!george From: george@hls0.hls.oz (George Turczynski) Newsgroups: comp.unix.questions Subject: Re: -F option for awk Summary: Works fine... Keywords: awk field-separator Message-ID: <848@hls0.hls.oz> Date: 14 Aug 90 00:03:36 GMT References: <491@llnl.LLNL.GOV> Lines: 20 In article <491@llnl.LLNL.GOV>, rjshaw@ramius.ocf.llnl.gov (Robert Shaw) writes: > When awk'ing something like a passwd file, where the reasonable choice > of field separator is something other than whitespace, how do you > let a line simply fall through and be printed unchanged? > I must have misunderstood your question. This works fine: tmp: awk -F: '{ if( $1 == "nobody" ) print }' /etc/passwd nobody:*:-2:-2::/: This is under SunOS 4.0.3, and works for both sh & csh. I don't know what you're running, but it might have been useful to know >:-} -- | George P. J. Turczynski. |---------------------------------------------------- | Computer Systems Engineer. | ACSnet: george@highland.oz | I can't speak for the | | Highland Logic Pty. Ltd. | Phone: +61 48 683490 | company, I can barely | | Suite 1, 348-354 Argyle St | Fax: +61 48 683474 | speak for myself... | | Moss Vale. NSW. Australia. 2577 |----------------------------------------------------