Where is LC_COLLATE documented or used? There is no man page for it. I thought it might be in some startup script, but a find on /etc came up empty. Help??!

Jim Hartley

Adam wrote:
[email protected] wrote:
Perhaps you can `export LC_COLLATE=C'. This would give you the result
I think you're after. Sorry, even though I have all other LANG/LC_* as
en_US.UTF-8, LC_COLLATE is the one I have set to C. :-)

$ cat abc
a0b
a4b
a8b
a`b
a=b
a_b

$ LC_COLLATE=en_US.UTF-8 sort abc
a0b
a4b
a8b
a`b
a=b
a_b

$ LC_COLLATE=C sort abc
a0b
a4b
a8b
a=b
a_b
a`b

The LC_COLLATE=C case has perfectly ascending bytes.

-jesse
Thanks, Jesse, that's exactly what I was looking for! That also explains why its default behavior was not what I was expecting. Time to study LC_COLLATE!

Adam

_______________________________________________
Mid-Hudson Valley Linux Users Group                  http://mhvlug.org
http://mhvlug.org/cgi-bin/mailman/listinfo/mhvlug
Upcoming Meetings (6pm - 8pm)                         MHVLS Auditorium
 Mar 7 - Web Hack-a-thon - SUNY Newpaltz
 Apr 1 - EC2 and Cloud Computer
 May 6 - TBD


--
Teen Angel - a ghost story - http://teenangel.netfirms.com
_______________________________________________
Mid-Hudson Valley Linux Users Group                  http://mhvlug.org
http://mhvlug.org/cgi-bin/mailman/listinfo/mhvlug
Upcoming Meetings (6pm - 8pm)                         MHVLS Auditorium
 Mar 7 - Web Hack-a-thon - SUNY Newpaltz
 Apr 1 - EC2 and Cloud Computer
 May 6 - TBD

Reply via email to