Re: How to add locale support for each column?

Поиск
Список
Период
Сортировка
Искать
От
Greg Stark
Тема
Re: How to add locale support for each column?
Дата
Msg-id
87ekkykzso.fsf@stark.xeocode.com
Ответ на
Список
Дерево обсуждения
How to add locale support for each column? Mahmoud Taghizadeh <m_taghi@yahoo.com>
Re: How to add locale support for each column? Peter Eisentraut <peter_e@gmx.net>
Re: How to add locale support for each column? Tatsuo Ishii <t-ishii@sra.co.jp>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Tom Lane <tgl@sss.pgh.pa.us>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Stephan Szabo <sszabo@megazone.bigpanda.com>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Stephan Szabo <sszabo@megazone.bigpanda.com>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Mahmoud Taghizadeh <m_taghi@yahoo.com>
Re: How to add locale support for each column? Tom Lane <tgl@sss.pgh.pa.us>
Re: How to add locale support for each column? Dennis Bjorklund <db@zigo.dhs.org>
Re: How to add locale support for each column? Greg Stark <gsstark@mit.edu>
Re: How to add locale support for each column? Stephan Szabo <sszabo@megazone.bigpanda.com>
Re: How to add locale support for each column? Dennis Bjorklund <db@zigo.dhs.org>
Peter Eisentraut  writes:

> 2) switching the locale at run time is too expensive when using the system
> library.

Fwiw I did some experiments with this and found it wasn't true. At least with
glibc I could switch the locale to what I wanted and back for every record in
a million record table with basically no noticeable effect on the query
execution time.

Of course not every system will have an equally speedy implementation. But I
don't think that's an argument for postgres to reimplement portions of the OS.
If the OS locale handling is slow on some OS's then postgres should just warn
its users that using locales on those OS's will be slow.

In any case I suspect more than just the glibc implementation cache locales in
memory at this point. It seems like just too obvious a feature and more and
more applications require locale switching to be fast anyways.

-- 
greg


В списке pgsql-hackers по дате отправления
От: Michael Paesold
Дата:
Сообщение: Re: SAVEPOINT SQL conformance
От: Michael Paesold
Дата:
FAQ