Received: from postgresql.org.org (webmail.postgresql.org [216.126.85.28]) by postgresql.org (8.11.3/8.11.1) with SMTP id f4GKFQA92869 for ; Wed, 16 May 2001 16:15:26 -0400 (EDT) (envelope-from pgsql-sql-owner@postgresql.org) Received: from news.tht.net (news.hub.org [216.126.91.242]) by postgresql.org (8.11.3/8.11.1) with ESMTP id f4GIRIA16110 for ; Wed, 16 May 2001 14:27:18 -0400 (EDT) (envelope-from news@news.tht.net) Received: (from news@localhost) by news.tht.net (8.11.1/8.11.1) id f4GILNI80807 for pgsql-sql@postgresql.org; Wed, 16 May 2001 14:21:23 -0400 (EDT) (envelope-from news) From: spam@freeuk.com (Stephen Patterson) X-Newsgroups: comp.databases.postgresql.sql Subject: case insensitive sort for output from SELECT Reply-To: see.the.sig@news.tht.net Message-ID: User-Agent: slrn/0.9.6.2 (Linux) Organization: clara.net http://www.clara.net/ Date: Wed, 16 May 2001 19:21:22 BST Lines: 24 X-Complaints-To: abuse@clara.net To: pgsql-sql@postgresql.org X-Archive-Number: 200105/173 X-Sequence-Number: 2990 Is there any way to alphabetically sort the output of a select statement correctly? what I'm using at the moment is SELECT data FROM table ORDER BY DATA ASC which gives (for example) A B C a b Is there any way to rig this so that it sorts 'properly', i.e. both the a's come together? Given what I'm working on, I could use either a pure SQL solution or some perl to put around the perl DBI. -- It's a great big universe and we're all really puny, just tiny little specks 'bout the size of Mickey Rooney -- Animaniacs -- -- -- -- -- -- -- -- -- -- Stephen Patterson s.patterson@SPAMOFFfreeuk.com (Remove SPAMOFF to reply) http://home.freeuk.net/s.patterson/