Re: Wire protocol: type-specific opt-in to binary format

Поиск
Список
Период
Сортировка
От Florian Pflug
Тема Re: Wire protocol: type-specific opt-in to binary format
Дата
Msg-id 826A9A7A-4DA0-4B2D-B252-01AA02E48624@phlo.org
обсуждение исходный текст
Ответ на Re: Wire protocol: type-specific opt-in to binary format  (Florian Weimer <fweimer@bfk.de>)
Ответы Re: Wire protocol: type-specific opt-in to binary format  (Florian Weimer <fweimer@bfk.de>)
Список pgsql-hackers
On Nov24, 2011, at 15:04 , Florian Weimer wrote:
> * Florian Pflug:
>> On Nov24, 2011, at 10:03 , Florian Weimer wrote:
>>> I would like to add functionality which allows a client to tell the
>>> server which types can be sent in binary format.  The immediate goal is
>>> to suppress hex quoting for BYTEA values, but it seems to make sense to
>>> make this functionality more general.
>> 
>> If you use the extended query protocol, the client can already choose
>> text vs. binary representation on a per-column basis. You can query
>> the result's column types by issuing a Describe message after the
>> Parse message.  For each column you can then decide whether you want
>> textual or binary representation, and include that choice in the
>> subsequent Bind message.
> 
> Interesting.  Doesn't this introduce another roundtrip?

Yes. Maybe that's also something that should go on the next protocol version
todo list. 

In any case, this is something that solely concerns the client library
(libpq, JDBC, ...), not users of that library, and should thus be handled
on the protocol level, not via a GUC.

best regards,
Florian Pflug



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

Предыдущее
От: Florian Weimer
Дата:
Сообщение: Re: Notes on implementing URI syntax for libpq
Следующее
От: Alexander Shulgin
Дата:
Сообщение: Re: Notes on implementing URI syntax for libpq