On Thursday 07 of July 2005 00:16, Gleb Paharenko wrote:
> Hello.
>
>
> For a pity, I could give explanations only for your query about
> selecting @@global.xxx variables. I think server returns correct
> results, because you're selecting global variables, while
> character_set_client, character_set_connection, character_set_results
> are session  variables. And with SET NAMES you're setting
> @@character_xxx variables which are synonym for @@session.character_xxx.
I see.

> In what way have you done your upgrade? If you haven't used mysqldump
> you could get some problems. Make the dump, and restore it setting
> the correct connection variables for mysql program. Be aware of that
> mysqldump could put SET NAMES at the beginning of the dump file. Use
> set-names=latin2 for it. See:
>   http://dev.mysql.com/doc/mysql/en/mysqldump.html
Dump & restore was done properly. dump on 4.0, add set names latin2; load into 
4.1. The problem is that by default connections from client are as latin1, db 
is latin2 so servers needs to do conversion from latin2->latin1 which can't 
be done and thus I'm getting '?' characters instead of latin2 characters.

The thing I need is how to force default latin2 in all client connections even 
if client won't request latin2 by using set names.

Tried doing things like in mysqld.conf:

init-connect = SET @lchar = IF(@@session.character_set_client = _utf8"latin1", 
@@global.character_set_client, @@session.character_set_client); SET 
character_set_client = @lchar; SET character_set_results = @lchar; SET 
character_set_connection = @lchar;

but that doesn't work unfortunately from init-connect (works from mysql 
cmdline client) ;-(
-- 
Arkadiusz Miƛkiewicz                    PLD/Linux Team
http://www.t17.ds.pwr.wroc.pl/~misiek/  http://ftp.pld-linux.org/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to