Path: utzoo!utgpu!water!watmath!clyde!rutgers!gatech!hubcap!ncrcae!ncr-sd!hp-sdd!ucsdhub!esosun!seismo!uunet!mcvax!ukc!stc!root44!gwc From: gwc@root.co.uk (Geoff Clare) Newsgroups: comp.unix.questions Subject: Using pipes within awk programs Summary: Is it OK to do this? Keywords: awk, pipe Message-ID: <515@root44.co.uk> Date: 12 Jan 88 17:41:59 GMT Reply-To: gwc@root.co.uk Organization: Unisoft Ltd, London, England Lines: 26 I have discovered that it is possible to send data down a pipe from within an awk program. For example who | awk '{ print $1 | "sort" }' gives the same output as who | awk '{ print $1 }' | sort I have tried this on a whole variety of flavours of UNIX, and it works on all of them. My question is this: I can't find any reference to this feature in any of our awk manuals, so is it safe to use it? and will it work on ALL systems or just some of them? (I have tried it on Uniplus+ V.2, BSD4.2, HP-UX, Sequent DYNIX, Tolerant TX). Any awk gurus out there? (or authors?!?). Answers to my specific question by email please, and I will summarise; but please don't inundate my mail box with general discussions of undocumented awk features - feel free to post those to the net. -- Geoff Clare gwc@root.co.uk seismo!mcvax!ukc!root44!gwc