Search Postgresql Archives

Re: Sorting in Unicode not working

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

 



Holger Klawitter <lists@klawitter.de> writes:
> So in other words, all databases inside postgres must have the same (or at
> least a compatible) encoding+locale

Yup.  strcoll()'s locale setting implicitly assumes a particular
encoding (at least on the platforms I'm familiar with), and so selecting
a database encoding that's incompatible with that will give you bizarre
sorting behavior.  The apparent freedom to select a per-database
encoding is really illusory in the current PG system, at least if you
have specific ideas about what you want the sort order to be.  You
pretty much have to get it right at initdb time.

There was a thread just a day or two back on pgsql-hackers about
generalizing our locale support, which would fix this problem among
others.  I'm not sure how soon it will really happen though...

			regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 4: Don't 'kill -9' the postmaster

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux