Re: Add encoding support to COPY

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема Re: Add encoding support to COPY
Дата
Msg-id 4A5E3EAE.6070402@dunslane.net
обсуждение исходный текст
Ответ на Re: Add encoding support to COPY  (Nagy Karoly Gabriel <nagy.karoly@expert-erp.net>)
Список pgsql-hackers

Nagy Karoly Gabriel wrote:
> David Blewett wrote:
>> Today on IRC, someone was wondering what the preferred method of
>> exporting data in a specific encoding via COPY was. They reply was
>> wrapping the COPY command in "set client_encoding='foo';", which made
>> me wonder how hard it would be to add an additional WITH parameter to
>> the actual COPY statement to specify the encoding, a la:
>>
> I think that I was the one who wondered about that. Our use case is 
> related to moving data between different servers which have different 
> encodings. Ofcourse the encoding should be an option only when COPY 
> involves files.
>


Well, that is the case that there seems to be consensus about, and it's 
also the case that can't be done via client encoding. We tend to have a 
bias against providing lots of ways to do the same thing, so let's go 
with this case (i.e. do it for cases other than STDIN/STDOUT).

cheers

andrew


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

Предыдущее
От: David Blewett
Дата:
Сообщение: Re: Add encoding support to COPY
Следующее
От: Heikki Linnakangas
Дата:
Сообщение: Re: Synch Rep for CommitFest 2009-07