MySQL/MariaDB创建数据库时指定UTF8编码

CREATE DATABASE IF NOT EXISTS dbname DEFAULT CHARSET utf8 COLLATE utf8_general_ci;
grant all on dbname.* to 'yachen'@'%' identified by 'pwd';
grant all on dbname.* to 'yachen'@'localhost' identified by 'pwd';

此处评论已关闭