mysterious sortorder issue

From: Andreas <maps(dot)on(at)gmx(dot)net>
To: ListaPostgre <pgsql-novice(at)postgresql(dot)org>
Subject: mysterious sortorder issue
Date: 2010-06-18 16:24:20
Message-ID: 4C1B9DB4.1090409@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

Hi,
I've got a produktive pg-server V8.4 on SuSE Linux and my dev-server on
winxp localhost.

The 2 servers produce different results in text sorting.
The local server sorts as expected but the productive db produces
unexpected orders.
They have identical data. The testbox has daily backups of the
productive db.

E.g. there is a table that holds projects.

A select project from projects order by project; delivers on
productive-db
....
StatStuff
S&T Evo
STP
S&T Polithings
Syback
....
How can the "STP" be between the two "S&T"s ?
Actually one should expect the two "S&T"s should appear as the first
projects with S because '&' < 'A'.

Another example is our " Sales" project. I made the blank in front to
get it always on the top of the list.
This works with PG on windows but PG on SUSE ignores the leading blank
and puts sales among the other projects that start with S.

The DB on WinXP is ENCODING = 'UTF8'
LC_COLLATE = 'German, Germany'
LC_CTYPE = 'German, Germany'

The DB on SUSE has ENCODING = 'UTF8'
LC_COLLATE = 'de_DE.UTF-8'
LC_CTYPE = 'de_DE.UTF-8'

There is no de_DE.UTF-8 on Windows and no German, Germany on SUSE so I
expect them as equal?

Can someone point me to the right server option that controls the sort
order to get the SUSE server right?

Browse pgsql-novice by date

  From Date Subject
Next Message Martin Knafve 2010-06-18 17:40:58 Bundling PostgreSQL
Previous Message Andreas 2010-06-18 16:18:48 Re: (not so?) silly question