Locale for Error Messages

Поиск
Список
Период
Сортировка
От George Sexton
Тема Locale for Error Messages
Дата
Msg-id 003301cc709d$ce051e00$6a0f5a00$@com
обсуждение исходный текст
Список pgsql-general

I run a SAS application that uses PostgreSQL. I’m working on enhancing my support for other languages. One of the things I noticed is that I’m getting my errors (say a unique key constraint) in English. This is expected. I know I’m not doing anything to change the locale.

 

I’d like to figure out how to get the errors in the user’s locale. I’m using JDBC to talk to the DB.

 

I looked at the documentation for localization and it appears that the locale for messages can be set for the database instance at startup by setting the LC_MESSAGES environment variable. I don’t want to have a different database instance for each language. Really, I’d just like a way of setting the locale prior to making a statement call.

 

I’ve looked at the SET command and the documentation for lc_messages(string) in section 18.10 of the manual and this doesn’t work because it requires Super User.

 

Is there a way to make this work? If not, is there an enhancement request queue I should submit this to?

 

                                      

George Sexton

MH Software, Inc.

303 438-9585

www.mhsoftware.com

 

В списке pgsql-general по дате отправления:

Предыдущее
От: Mudit Mishra
Дата:
Сообщение: writing block 6850 of relation 1663/17231/1259
Следующее
От: Chris Travers
Дата:
Сообщение: Re: Security setup.