🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.sun
Article #7008

Sorting problems

#7008
From: Mark Levison
Date: Mon, 18 Mar 1991 17:28
34 lines
1830 bytes
I have been trying to use the sort facility on machine (Sun 3/80, SunOS
4.0.3) for the past few days. I have run into several problems first the
-z option gets

maestrosh[277]sort -m -z 5000 breakup
sort: invalid use of command line options
maestrosh[278]

Second to avoid running out of memory during the sort phase I have had to
use the split function and then sort each file individually followed by a
merge phase. When merging the result I have tried to use the -u option ie.

sort -n -mu file1 file2 >! outputfile

but this causes sort to include only one of the following lines

-----line 1 (wrapped around to avoid news/mailer problems)
77 0 4408 4410 1 DOCUMENT 1 0 8 SECTION 1 7 9 HEADING 1 8
/DOCUMENT/SECTION/HEADING

-----line 2
77 0 4689 4690 1 DOCUMENT 1 0 8 SECTION 2 15 9 HEADING 1 16
/DOCUMENT/SECTION/HEADING

These lines are obviously different. In the short term I have gotten
around the problem by leaving the uniqing until after the merge phase and
using the uniq command which appears to work. As far as I can tell from
the man page the sort fields should be the entire line unless I specify
otherwise on the command line.

Can anyone shed some light on these on these two problems?

Mark Levison
levisonm@qucis.queensu.ca
Technical Details
Message-ID: <1956@brchh104.bnr.ca>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!cunews!bnrgate!brtph3!brchh104!brchs1!bnr.ca!rice.edu!sun-spots-request

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!cunews!bnrgate!brtph3!brchh104!brchs1!bnr.ca!rice.edu!sun-spots-request
From: levisonm@qucis.queensu.ca (Mark Levison)
Newsgroups: comp.sys.sun
Subject: Sorting problems
Keywords: Miscellaneous
Message-ID: <1956@brchh104.bnr.ca>
Date: 18 Mar 91 17:28:00 GMT
Sender: news@brchh104.bnr.ca
Organization: Sun-Spots
Lines: 34
Approved: Sun-Spots@rice.edu
X-Original-Date: 4 Mar 91 23:09:58 GMT
X-Sun-Spots-Digest: Volume 10, Issue 57, message 13
X-Note: Submissions: sun-spots@rice.edu, Admin: sun-spots-request@rice.edu