From unknown Fri Sep 12 09:19:11 2025 X-Loop: help-debbugs@gnu.org Subject: bug#9281: Is this expected behavior? Resent-From: Ajesh Shaj Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-coreutils@gnu.org Resent-Date: Thu, 11 Aug 2011 06:40:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 9281 X-GNU-PR-Package: coreutils X-GNU-PR-Keywords: To: 9281@debbugs.gnu.org X-Debbugs-Original-To: "bug-coreutils@gnu.org" Received: via spool by submit@debbugs.gnu.org id=B.131304477411859 (code B ref -1); Thu, 11 Aug 2011 06:40:04 +0000 Received: (at submit) by debbugs.gnu.org; 11 Aug 2011 06:39:34 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrOvS-00035B-1T for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:39:31 -0400 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrOpk-0002vS-AG for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:33:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QrOoT-0001g4-Qf for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:32:18 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-16.1 required=5.0 tests=BAYES_00,HTML_MESSAGE, NO_RDNS_DOTCOM_HELO, RCVD_IN_DNSWL_NONE, T_DKIM_INVALID, USER_IN_DEF_WHITELIST autolearn=no version=3.3.1 Received: from lists.gnu.org ([140.186.70.17]:35136) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoT-0001g0-PE for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:32:17 -0400 Received: from eggs.gnu.org ([140.186.70.92]:39667) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoS-0000hO-Vv for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QrOoS-0001fj-46 for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:16 -0400 Received: from mrout2-b.corp.re1.yahoo.com ([69.147.107.21]:47589) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoS-0001fd-1H for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:16 -0400 Received: from EGL-EX07CAS03.ds.corp.yahoo.com (egl-ex07cas03.eglbp.corp.yahoo.com [203.83.248.219]) by mrout2-b.corp.re1.yahoo.com (8.14.4/8.14.4/y.out) with ESMTP id p7B6VeQa025149 for ; Wed, 10 Aug 2011 23:31:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yahoo-inc.com; s=cobra; t=1313044301; bh=u5i/i9fIkhWXNf4v9YV8zYEQ7Wbf1ZrWS5VmU8WccM8=; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; b=XZSqR+nxwfhhUbCqz/dXBrWDSnflQlMUyFRUNtSOXoBelJpJg+Bpn3WGHbP6EyT4p rTdtfyrVaHsViLxiN4Ioywvf/OUwzUXh1bt18CV0P9K/URX0YZlPXyXasgUNcCvPNW NkcEghGy+nLzQV0HSg+hM+bYCfnQaVnKm1JF8wnU= Received: from EGL-EX07VS02.ds.corp.yahoo.com ([203.83.248.206]) by EGL-EX07CAS03.ds.corp.yahoo.com ([203.83.248.219]) with mapi; Thu, 11 Aug 2011 12:01:40 +0530 From: Ajesh Shaj Date: Thu, 11 Aug 2011 12:01:38 +0530 Thread-Topic: Is this expected behavior? Thread-Index: AcxX8FLPx+1gfiRIkkGV9A/yqwTA2A== Message-ID: Accept-Language: en-US Content-Language: en X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: multipart/alternative; boundary="_000_CA6975226400ajeshyahooinccom_" MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.17 X-Spam-Score: -5.9 (-----) X-Mailman-Approved-At: Thu, 11 Aug 2011 02:39:28 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.9 (-----) --_000_CA6975226400ajeshyahooinccom_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, I got a strange ordering when I applied the linux sort command. Please = see below for the details: [ajesh@gwta3004 tmp]$ cat a .a ba .b bb .c bc [ajesh@gwta3004 tmp]$ sort a .a .b ba bb bc .c NOTE: .a and .b appears before ba and bb, where as .c appears after bc. In general if the file has strings of the type . and , then for all x <=3D y, .x appear before yx and for all x>y, .x appear after yx Is this expected behavior? Regards Ajesh -- --_000_CA6975226400ajeshyahooinccom_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Is this expected behavior? Hi,

    I got a strange ordering when I applied the linux s= ort command. Please see below for the details:

[ajesh@gwta3004 tmp]$ cat a
.a
ba
.b
bb
.c
bc
[ajesh@gwta3004 tmp]$ sort a
.a
.b
ba
bb
bc
.c


NOTE: .a and .b appears before ba and bb, where as .c appears after bc.<= BR>
In general

if the file has strings of the type .<x> and <y><x>,

then for all x <=3D y, .x appear before yx and
          for all x>y,= .x appear after yx

Is this expected behavior?

Regards
Ajesh

--

--_000_CA6975226400ajeshyahooinccom_-- From unknown Fri Sep 12 09:19:11 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.427 (Entity 5.427) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Ajesh Shaj Subject: bug#9281: closed (Re: bug#9281: Is this expected behavior?) Message-ID: References: <4E43C560.8020609@redhat.com> X-Gnu-PR-Message: they-closed 9281 X-Gnu-PR-Package: coreutils Reply-To: 9281@debbugs.gnu.org Date: Thu, 11 Aug 2011 12:07:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1313064422-12090-1" This is a multi-part message in MIME format... ------------=_1313064422-12090-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #9281: Is this expected behavior? which was filed against the coreutils package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 9281@debbugs.gnu.org. --=20 9281: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D9281 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1313064422-12090-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 9281-done) by debbugs.gnu.org; 11 Aug 2011 12:06:28 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrU1q-00038C-E5 for submit@debbugs.gnu.org; Thu, 11 Aug 2011 08:06:27 -0400 Received: from mx1.redhat.com ([209.132.183.28]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrU1n-000384-0S for 9281-done@debbugs.gnu.org; Thu, 11 Aug 2011 08:06:24 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p7BC535F022007 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Thu, 11 Aug 2011 08:05:03 -0400 Received: from [10.3.113.66] (ovpn-113-66.phx2.redhat.com [10.3.113.66]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p7BC52pC017524; Thu, 11 Aug 2011 08:05:03 -0400 Message-ID: <4E43C560.8020609@redhat.com> Date: Thu, 11 Aug 2011 06:04:48 -0600 From: Eric Blake Organization: Red Hat User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110621 Fedora/3.1.11-1.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.11 MIME-Version: 1.0 To: Ajesh Shaj Subject: Re: bug#9281: Is this expected behavior? References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 X-Spam-Score: -10.3 (----------) X-Debbugs-Envelope-To: 9281-done Cc: 9281-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -10.3 (----------) tag 9281 notabug thanks On 08/11/2011 12:31 AM, Ajesh Shaj wrote: > Hi, > > I got a strange ordering when I applied the linux sort command. Please see below for the details: > > [ajesh@gwta3004 tmp]$ sort a > .a > .b > ba > bb > bc > .c > > > NOTE: .a and .b appears before ba and bb, where as .c appears after bc. > Is this expected behavior? Yep. And this is a FAQ, caused by you using a locale that ignores punctuation when determining sort order. https://www.gnu.org/software/coreutils/faq/#Sort-does-not-sort-in-normal-order_0021 If you are using new enough coreutils, try: sort --debug a for better understanding what is happening, then compare to: LC_ALL=C sort --debug a (if your sort doesn't understand --debug, then it is still useful to try LC_ALL=C sort a). -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org ------------=_1313064422-12090-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 11 Aug 2011 06:39:34 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrOvS-00035B-1T for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:39:31 -0400 Received: from eggs.gnu.org ([140.186.70.92]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1QrOpk-0002vS-AG for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:33:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QrOoT-0001g4-Qf for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:32:18 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-16.1 required=5.0 tests=BAYES_00,HTML_MESSAGE, NO_RDNS_DOTCOM_HELO, RCVD_IN_DNSWL_NONE, T_DKIM_INVALID, USER_IN_DEF_WHITELIST autolearn=no version=3.3.1 Received: from lists.gnu.org ([140.186.70.17]:35136) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoT-0001g0-PE for submit@debbugs.gnu.org; Thu, 11 Aug 2011 02:32:17 -0400 Received: from eggs.gnu.org ([140.186.70.92]:39667) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoS-0000hO-Vv for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:17 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QrOoS-0001fj-46 for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:16 -0400 Received: from mrout2-b.corp.re1.yahoo.com ([69.147.107.21]:47589) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QrOoS-0001fd-1H for bug-coreutils@gnu.org; Thu, 11 Aug 2011 02:32:16 -0400 Received: from EGL-EX07CAS03.ds.corp.yahoo.com (egl-ex07cas03.eglbp.corp.yahoo.com [203.83.248.219]) by mrout2-b.corp.re1.yahoo.com (8.14.4/8.14.4/y.out) with ESMTP id p7B6VeQa025149 for ; Wed, 10 Aug 2011 23:31:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=yahoo-inc.com; s=cobra; t=1313044301; bh=u5i/i9fIkhWXNf4v9YV8zYEQ7Wbf1ZrWS5VmU8WccM8=; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; b=XZSqR+nxwfhhUbCqz/dXBrWDSnflQlMUyFRUNtSOXoBelJpJg+Bpn3WGHbP6EyT4p rTdtfyrVaHsViLxiN4Ioywvf/OUwzUXh1bt18CV0P9K/URX0YZlPXyXasgUNcCvPNW NkcEghGy+nLzQV0HSg+hM+bYCfnQaVnKm1JF8wnU= Received: from EGL-EX07VS02.ds.corp.yahoo.com ([203.83.248.206]) by EGL-EX07CAS03.ds.corp.yahoo.com ([203.83.248.219]) with mapi; Thu, 11 Aug 2011 12:01:40 +0530 From: Ajesh Shaj To: "bug-coreutils@gnu.org" Date: Thu, 11 Aug 2011 12:01:38 +0530 Subject: Is this expected behavior? Thread-Topic: Is this expected behavior? Thread-Index: AcxX8FLPx+1gfiRIkkGV9A/yqwTA2A== Message-ID: Accept-Language: en-US Content-Language: en X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: multipart/alternative; boundary="_000_CA6975226400ajeshyahooinccom_" MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.17 X-Spam-Score: -5.9 (-----) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Thu, 11 Aug 2011 02:39:28 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.9 (-----) --_000_CA6975226400ajeshyahooinccom_ Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hi, I got a strange ordering when I applied the linux sort command. Please = see below for the details: [ajesh@gwta3004 tmp]$ cat a .a ba .b bb .c bc [ajesh@gwta3004 tmp]$ sort a .a .b ba bb bc .c NOTE: .a and .b appears before ba and bb, where as .c appears after bc. In general if the file has strings of the type . and , then for all x <=3D y, .x appear before yx and for all x>y, .x appear after yx Is this expected behavior? Regards Ajesh -- --_000_CA6975226400ajeshyahooinccom_ Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Is this expected behavior? Hi,

    I got a strange ordering when I applied the linux s= ort command. Please see below for the details:

[ajesh@gwta3004 tmp]$ cat a
.a
ba
.b
bb
.c
bc
[ajesh@gwta3004 tmp]$ sort a
.a
.b
ba
bb
bc
.c


NOTE: .a and .b appears before ba and bb, where as .c appears after bc.<= BR>
In general

if the file has strings of the type .<x> and <y><x>,

then for all x <=3D y, .x appear before yx and
          for all x>y,= .x appear after yx

Is this expected behavior?

Regards
Ajesh

--

--_000_CA6975226400ajeshyahooinccom_-- ------------=_1313064422-12090-1-- From debbugs-submit-bounces@debbugs.gnu.org Tue Sep 20 14:00:18 2011 Received: (at control) by debbugs.gnu.org; 20 Sep 2011 18:00:18 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1R64cE-0001Nm-1X for submit@debbugs.gnu.org; Tue, 20 Sep 2011 14:00:18 -0400 Received: from mx1.redhat.com ([209.132.183.28]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1R64cA-0001HV-6g for control@debbugs.gnu.org; Tue, 20 Sep 2011 14:00:16 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p8KHt5Ml011230 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 20 Sep 2011 13:55:05 -0400 Received: from [10.3.113.135] (ovpn-113-135.phx2.redhat.com [10.3.113.135]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id p8KHt4iN031217 for ; Tue, 20 Sep 2011 13:55:05 -0400 Message-ID: <4E78D378.3060907@redhat.com> Date: Tue, 20 Sep 2011 11:55:04 -0600 From: Eric Blake Organization: Red Hat User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.22) Gecko/20110906 Fedora/3.1.14-1.fc14 Lightning/1.0b3pre Mnenhy/0.8.3 Thunderbird/3.1.14 MIME-Version: 1.0 To: control@debbugs.gnu.org Subject: more work Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-Spam-Score: -10.3 (----------) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -10.3 (----------) tag 9507 notabug forcemerge 6394 9507 tag 9504 notabug tag 9449 notabug tag 9450 wishlist tag 9418 notabug tag 9380 notabug tag 9327 notabug tag 9326 notabug tag 9283 notabug tag 9281 notabug thanks -- Eric Blake eblake@redhat.com +1-801-349-2682 Libvirt virtualization library http://libvirt.org