Re: RPM question: Where to put psycopg2 files

Поиск
Список
Период
Сортировка
От Federico Di Gregorio
Тема Re: RPM question: Where to put psycopg2 files
Дата
Msg-id 4D3449CC.1090004@dndg.it
обсуждение исходный текст
Ответ на Re: RPM question: Where to put psycopg2 files  (Daniele Varrazzo <daniele.varrazzo@gmail.com>)
Ответы Re: RPM question: Where to put psycopg2 files  (Daniele Varrazzo <daniele.varrazzo@gmail.com>)
Re: RPM question: Where to put psycopg2 files  (Karsten Hilbert <Karsten.Hilbert@gmx.net>)
Список psycopg
On 17/01/2011 14:35, Daniele Varrazzo wrote:
> The problem is that postgres 9 uses by default the hex format instead
> of the escape format to represent bytea
> (http://www.postgresql.org/docs/9.0/static/datatype-binary.html). A
> workaround I was thinking about could be to send "SET bytea_output TO
> 'escape';" on connection in case of pre9-libpq/post9-server
> combination is detected. I hate it because I was trying to drop the
> "queries on connection" psycopg does (there used to be 3, now there is
> only one and I think the last one can be dropped as well).

Please lets not do that. psycopg can already be used with a lesser libpq
to connect to a newer backend _unless_ changes like the one in this
discussion. Solving this particular problem may seem a good thing but,
IMHO, it is just putting a workaround in the wrong place.

> Of course
> bytea_output can be set in the postgresql.conf too and it would make
> previous releases of psycopg work fine.

That's the correct workaround.

federico

--
Federico Di Gregorio                         federico.digregorio@dndg.it
Studio Associato Di Nunzio e Di Gregorio                  http://dndg.it
                   I came like Water, and like Wind I go. -- Omar Khayam

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

Предыдущее
От: Daniele Varrazzo
Дата:
Сообщение: Re: RPM question: Where to put psycopg2 files
Следующее
От: Harald Armin Massa
Дата:
Сообщение: Re: RPM question: Where to put psycopg2 files