is there a default client encoding?

is there a default client encoding?

am 26.01.2006 19:57:47 von Jaime Casanova

Hi,

i wonder if the odbc driver is sending a default client_encoding to
the server. if so, what client_encoding? how can i determine it? if
not, how i know what client encoding my platform uses?

the question is because before i meet linux i never heard the term
encoding... windows does everything for you and hides all this littles
things (so when i start using the odbc driver in windows i never use
client_encoding command now i know that is why some client
applications got weird results ;). Well the point is in VB i can't
send arbitrary commands to the server so how i set it, is the odbc
doing it? can i change the encoding the odbc is sending?

--
regards,
Jaime Casanova
(DBA: DataBase Aniquilator ;)

---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Re: is there a default client encoding?

am 26.01.2006 20:03:06 von Ludek Finstrle

> i wonder if the odbc driver is sending a default client_encoding to
> the server. if so, what client_encoding? how can i determine it? if
> not, how i know what client encoding my platform uses?

psqlODBC tries to do it automatically for you. If you want see what
client_encoding is used enable mylog output and there is called
set client_encoding in the relative begin of mylog.

> applications got weird results ;). Well the point is in VB i can't
> send arbitrary commands to the server so how i set it, is the odbc
> doing it? can i change the encoding the odbc is sending?

The psqlODBC has strange behaviour. It set automatic client_encoding
_after_ user defined connection settings. So you could change the
client encoding only from application. You could call
set client_encoding SQL statement.

I hope I have answered you

Luf

---------------------------(end of broadcast)---------------------------
TIP 6: explain analyze is your friend

Re: is there a default client encoding?

am 26.01.2006 20:34:39 von Jaime Casanova

>
> I hope I have answered you
>
> Luf
>

yes... with a very good answer... i will look at the code to see how
psqlODBC tries to guess the encoding... thanx a lot...

--
regards,
Jaime Casanova
(DBA: DataBase Aniquilator ;)

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

http://archives.postgresql.org

Re: is there a default client encoding?

am 13.07.2009 22:17:53 von Neil Best

Ludek Finstrle-2 wrote:
>
>
> psqlODBC tries to do it automatically for you. If you want see what
> client_encoding is used enable mylog output and there is called
> set client_encoding in the relative begin of mylog.
>
> . . .
>
> The psqlODBC has strange behaviour. It set automatic client_encoding
> _after_ user defined connection settings. So you could change the
> client encoding only from application. You could call
> set client_encoding SQL statement.
>

Is this still how the driver behaves? I don't see client_encoding
explicitly in mylog when I leave the Connection Settings input blank in the
ODBC configuration. I have tried entering "set client_encoding = 'WIN874';"
and it seems to be ignored altogether.

Is there something I can do in the Control Panel or elsewhere to control the
client encoding? I am trying to load some MS Access data that has Thai
characters (WIN874 = "Thai (Windows)") to a Postgres server via ODBC using
either Access 2007 or Stat/Transfer 9, neither of which give me an
opportunity to set the client encoding after the connection has been made.

The ODBCng driver seems to offer some control over the client encoding but
when I use that driver most of my records do not make it to the Postgres
database for some reason when using Stat/Transfer and Access just crashes.

Any ideas? Thanks.

Neil
--
View this message in context: http://www.nabble.com/is-there-a-default-client-encoding--tp 2604857p24468213.html
Sent from the PostgreSQL - odbc mailing list archive at Nabble.com.


--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: is there a default client encoding?

am 15.07.2009 05:56:07 von Hiroshi Inoue

Neil Best wrote:
>
>
> Ludek Finstrle-2 wrote:
>>
>> psqlODBC tries to do it automatically for you. If you want see what
>> client_encoding is used enable mylog output and there is called
>> set client_encoding in the relative begin of mylog.
>>
>> . . .
>>
>> The psqlODBC has strange behaviour. It set automatic client_encoding
>> _after_ user defined connection settings. So you could change the
>> client encoding only from application. You could call
>> set client_encoding SQL statement.
>>
>
> Is this still how the driver behaves? I don't see client_encoding
> explicitly in mylog when I leave the Connection Settings input blank in the
> ODBC configuration. I have tried entering "set client_encoding = 'WIN874';"
> and it seems to be ignored altogether.

Please try to enter "set client_encoding to 'WIN874'".

regards,
Hiroshi Inoue


--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc