Path: utzoo!attcan!uunet!microsoft!t-rayc From: t-rayc@microsoft.UUCP (Raymond CHEN) Newsgroups: comp.sys.ibm.pc Subject: Re: sorting multiple-line records Message-ID: <55708@microsoft.UUCP> Date: 7 Jul 90 22:30:32 GMT References: <1601@ole.UUCP> Reply-To: t-rayc@microsoft.UUCP (Raymond CHEN) Distribution: na Organization: Microsoft Corp., Redmond WA Lines: 11 Somebody else mentioned awk. You might also want to consider Larry Wall's perl program, though it might be overkill for this particular task. It is distributed under the GNU guidelines, and Diomidis Spinellis (dds@cc.ic.ac.uk) ported it to MS-DOS. PD1:PERL3.ZIP on SIMTEL20. With perl, your task becomes a one-liner, assuming, say, that records are separated by a blank line. perl -e "$/='';print sort ;" outfile