Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!newstop!exodus!bike2work.Eng.Sun.COM!bm From: bm@bike2work.Eng.Sun.COM (Bill Michel) Newsgroups: comp.unix.questions Subject: Narly Nawk Script Message-ID: <4255@exodus.Eng.Sun.COM> Date: 10 Dec 90 22:56:05 GMT Sender: news@exodus.Eng.Sun.COM Reply-To: bm@bike2work.Eng.Sun.COM (Bill Michel) Organization: Sun Microsystems, Inc. Mt. View, Ca. Lines: 47 I'm working on a shell script that makes extensive use of (n)awk. I'm *really confused as to the general workings of the script, and would apprecieate some help. Assume my script to be called "nawkfile" it is invoked as follows: nawkfile inputfile where inputfile is the file containing the input to be processed. My main questions are : 1) where does the data put into "string" go after the first call to nawk? 2) does $* mean a recursive call to the script, if so, how can this be used as input to the second nawk call Thanks in advance -------------------------------- The general layout is as follows nawk ' { process a bunch of text, and append it to the variable "string" } END { print string } ' $* | nawk ' { do some more processing }' | nawk ' { do some more processing and send the output to a file } -- Bill Michel bm@eng.sun.com These views are my own, not Sun's.