bug-textutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in sort?


From: Henk M. Keller, AT Computing BV
Subject: Re: Bug in sort?
Date: Thu, 11 Jan 2001 11:52:34 +0100

Hello Bob,

On january 10, 2001, 11:07 Bob Proulx wrote:
<CUT>
> Thank you for your report.  Jim has previously answered these reports
> with something similar to the the following reply. 
<CUT>

Thanks for your very speedy reply on my email concerning a sort problem.
>From Microsoft, I would probably have received a machine generated answer
"with the next major release, your problem might be solved"...

Alas, I am afraid my sort problem is more serious than Jim's answer suggests:
When sorting numerically, even *identical* lines pop up in different places
in the output!
Setting the environment variable LC_ALL does not change this behavior.
A typescript demonstrating this problem:

===== Start of typescript
Script started on Thu Jan 11 10:32:51 2001
demo$ uname -a
Linux pantarhei.ATComputing.nl 2.2.14-5.0 #1 Tue Mar 7 21:07:39 EST 2000 i686 
unknown
demo$ sort --version
sort (GNU textutils) 2.0a
Written by Mike Haertel.

Copyright (C) 1999 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
demo$ cat demo-in
2
1
4
3
5
4
demo$ printenv|grep LC
demo$ sort -n demo-in
4
2
4
1
5
3
demo$ export LC_ALL=POSIX
demo$ sort -n demo-in
4
2
4
1
5
3
demo$ exit
Script done on Thu Jan 11 10:33:46 2001
===== End of typescript

Prepending the data with a space character solves my current problem, but
of course it is not a very elegant situation!

Greetings from a GNU Patron, and keep up the excellent GNU work!
-- 
----- address@hidden ------- http://www.ATComputing.nl
Henk M. Keller - AT Computing, P.O. Box 1428, NL-6501BK Nijmegen
+31-24-3527252 (fax: 3527292)   UNIX training and consultancy
      Linux is a good UNIX, and we do UNIX training...
Please send mails and files in ASCII, HTML or Postscript; No MSWord!



reply via email to

[Prev in Thread] Current Thread [Next in Thread]