Re: Charset encoding patch to JDBC driver
От | Oliver Jowett |
---|---|
Тема | Re: Charset encoding patch to JDBC driver |
Дата | |
Msg-id | 4238173D.60307@opencloud.com обсуждение исходный текст |
Ответ на | Charset encoding patch to JDBC driver (Javier Yáñez <javier@cibal.es>) |
Ответы |
Re: Charset encoding patch to JDBC driver
Re: Charset encoding patch to JDBC driver |
Список | pgsql-jdbc |
Javier Yáñez wrote: > I have the necesity of to keep a PostgreSQL database with SQL-ASCII. As > the actual version of pgjdbc only have support for Unicode (at least for > jdbc3), I have make a patch that allow to configure the desired charset. I'm uncomfortable with applying this sort of patch to the official driver, since it makes the driver more complex just to handle what is arguably a database misconfiguration. It also introduces a new class of error: a mismatch between the driver's configured charSet and the actual database. Comments on the patch itself: - it is missing changes to the v2 protocol path - why does it remove the client_encoding sanity check on connect? - since encoding does not change for the lifetime of the connection, can't you make the encoding a field of QueryExecutoryImpl rather than passing it around everywhere? - it may be better to pass encoding as a parameter to SimpleParameterList methods that need it, rather than storing the (same) value on every list instance. -O
В списке pgsql-jdbc по дате отправления: