Re: libpq PGresult object and encoding

From: Jeroen Vermeulen <jtv(at)xs4all(dot)nl>
To: Jeff Davis <pgsql(at)j-davis(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: libpq PGresult object and encoding
Date: 2010-02-17 22:32:59
Message-ID: 4B7C6E9B.705@xs4all.nl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jeff Davis wrote:
> libpq has a PQclientEncoding() function that takes a connection object.
>
> However, the client encoding is, in some cases, a property of the result
> object. For instance, if your client_encoding changes, but you keep the
> result object around, you have no way to determine later what encoding
> the results are in.
>
> The result object already saves the client_encoding. Should an accessor
> be provided?

That'd certainly save libpqxx the trouble of lugging a copy around.

Jeroen

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Jeroen Vermeulen 2010-02-17 22:52:14 Re: Avoiding bad prepared-statement plans.
Previous Message Alvaro Herrera 2010-02-17 22:12:03 Re: alpha4 timing