Joe Conway <mail(at)joeconway(dot)com> writes:
> Tom Lane wrote:
>> you will need to whip up a special-purpose quoting subroutine.
> OK, I see that. I assume I need to care for encoding issues? If so, do I
> assume server encoding or client encoding?
Hoo, good point. You can assume the database (server) encoding, because
that's what the local encoding is from the point of view of libpq ---
and the code in conninfo_parse knows nothing of encodings anyway. So
that's a no-op as far as the quoting itself goes. But that reminds me,
weren't you going to add something to force libpq to set client_encoding
to the database encoding?
regards, tom lane