【1】修改存储引
ALTER TABLE `qipa250_articles` ENGINE=INNODB; ALTER TABLE `qipa250_articles_text` ENGINE=INNODB; ALTER TABLE `qipa250_authors` ENGINE=INNODB; ALTER TABLE `qipa250_comments` ENGINE=INNODB; ALTER TABLE `qipa250_comments_description` ENGINE=INNODB; ALTER TABLE `popular_searches` ENGINE=INNODB; ALTER TABLE `un_products_to_wishlists` ENGINE=INNODB; ALTER TABLE `un_wishlists` ENGINE=INNODB;
【2】修改字符集与排序规则
-- 修改数据库默认字符集与排序规则
ALTER DATABASE `zcqipa250` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci; -- 修改表字符集与排序规则
-- 有数据的情况下 ALTER TABLE `qipa250_articles` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `qipa250_articles_text` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `qipa250_authors` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `qipa250_comments` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `qipa250_comments_description` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `popular_searches` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `un_products_to_wishlists` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci; ALTER TABLE `un_wishlists` CONVERT TO CHARACTER SET utf8 COLLATE utf8_general_ci;
-- 修改字段的
alter table `t_settle_apply ` modify column nike_name varchar(500) character set utf8 collate utf8_general_ci comment '昵称';
【3】修改行格式
ALTER TABLE 表名 ROW_FORMAT=行格式名称
标签:ci,qipa250,utf8,字符集,general,修改,mysql,TABLE,ALTER From: https://www.cnblogs.com/gered/p/17189550.html