List:General Discussion« Previous MessageNext Message »
From:Duane Hill Date:November 18 2011 4:09am
Subject:Re: how do I make utf8 the default encoding for my MySQL installation
View as plain text  
On Friday, November 18, 2011 at 03:31:44 UTC, martin.mueller@stripped confabulated:

> Is it possible to make utf8 the default for all databases and transactions
> in a MySQL installation?

> The current default is Latin1. There is a suggestion on the Web to edit
> the my.cnf file as follows


> [mysqld]
> init_connect=’SET collation_connection = utf8_general_ci’
> init_connect=’SET NAMES utf8′
> default-character-set=utf8
> character-set-server=utf8
> collation-server=utf8_general_ci
> skip-character-set-client-handshake

> On a Mac with MySQL 5.5.17 this produces the error

>  [ERROR] /usr/local/mysql/bin/mysqld: unknown variable
> 'default-character-set=utf8'

> The Reference Manual is very tortuous but lacks instructions that are
> clear to a not very technical user. 

http://dev.mysql.com/doc/refman/5.5/en/server-options.html#option_mysqld_default-character-set

The above link says default-character-set is depreciated and you should
be   using  character-set-server. It also states default-character-set
was removed in v5.5.3.

You should be able to remove the option.

-- 
There  are  10  kinds  of  people in the world... Those who understand
binary, and those who don't.

Thread
ibdata1 and undo logKay [DAS] Rozeboom16 Nov
  • Re: ibdata1 and undo logJohan De Meersman17 Nov
    • how do I make utf8 the default encoding for my MySQL installationMartin Mueller18 Nov
      • Re: how do I make utf8 the default encoding for my MySQL installationDuane Hill18 Nov
      • Re: how do I make utf8 the default encoding for my MySQL installationReindl Harald18 Nov
    • RE: ibdata1 and undo logKay [DAS] Rozeboom18 Nov
      • Re: ibdata1 and undo logJohan De Meersman19 Nov