mysql charater set
* character set 확인
mysql> show variables like 'c%';
* my.cnf 수정
[root@localhost local]# vi /etc/my.cnf
[client]
#추가
default-character-set = utf8
[mysqld]
#추가
init_connect= SET collation_connection = utf8_general_ci
init_connect= SET NAMES utf8
character-set-server = utf8
collation-server = utf8_general_ci
[mysqldump]
#추가
default-character-set = utf8
[mysql]
#추가
default-character-set = utf8
* mysql 재시작
[root@localhost local]# service mysqld restart
mysqld 를 정지 중: [ OK ]
mysqld (을)를 시작 중: [ OK ]
[root@localhost local]#
댓글 없음:
댓글 쓰기