#cap deploy:cold 的时候报错
mysql2::Error: Invalid default value for 'country': CREATE TABLE ship_addresses
(id
int(11) DEFAULT NULL auto_increment PRIMARY KEY, user_id
int(11), country
varchar(255) DEFAULT '中国', state
varchar(255), city
varchar(255), district
varchar(255), address
varchar(255), contact_name
varchar(255), mobile
varchar(255), telephone
varchar(255), memo
varchar(255), created_at
datetime, updated_at
datetime) ENGINE=InnoDB
服务器环境是 ubuntu10.04 服务器上/etc/default/locale 中的编码设置是 LANG="en_US.UTF-8" /etc/mysql/my/cnf中已经设置了utf8编码 ·[client] default-character-set=utf8 ·[mysqld] default-character-set=utf8
mysql> show variables like 'character%'; +--------------------------+----------------------------+ | Variable_name | Value | +--------------------------+----------------------------+ | character_set_client | utf8 | | character_set_connection | utf8 | | character_set_database | utf8 | | character_set_filesystem | binary | | character_set_results | utf8 | | character_set_server | utf8 | # | character_set_system | utf8 | | character_sets_dir | /usr/share/mysql/charsets/ | +--------------------------+----------------------------+