* [refac] Remove explicit charset and collation declarations from SQL files

- Remove DEFAULT CHARSET declarations from all SQL table definitions
- Strip COLLATE clauses from field definitions across all database scripts
- Simplify ENGINE declarations by removing redundant charset specifications
- Standardize SQL statement formatting for improved database compatibility
- Affects all database update scripts from version 0.1 to 21.7.6
This commit is contained in:
liugang
2025-11-24 09:48:10 +08:00
parent 31cc4f28d6
commit d0b5ddb807
277 changed files with 19457 additions and 19528 deletions
+7 -7
View File
@@ -1,5 +1,5 @@
ALTER TABLE `zt_module` ADD `short` varchar(30) COLLATE 'utf8_general_ci' NOT NULL AFTER `owner`;
ALTER TABLE `zt_usertpl` ADD `public` enum('0','1') COLLATE 'utf8_general_ci' NOT NULL DEFAULT '0';
ALTER TABLE `zt_module` ADD `short` varchar(30) NOT NULL AFTER `owner`;
ALTER TABLE `zt_usertpl` ADD `public` enum('0','1') NOT NULL DEFAULT '0';
CREATE TABLE `zt_block` (
`id` mediumint(8) unsigned NOT NULL AUTO_INCREMENT,
`account` char(30) NOT NULL,
@@ -14,8 +14,8 @@ CREATE TABLE `zt_block` (
PRIMARY KEY (`id`),
UNIQUE KEY `accountModuleOrder` (`account`,`module`,`order`),
KEY `block` (`account`,`module`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8;
ALTER TABLE `zt_task` ADD `color` char(7) COLLATE 'utf8_general_ci' NOT NULL AFTER `status`;
ALTER TABLE `zt_story` ADD `color` char(7) COLLATE 'utf8_general_ci' NOT NULL AFTER `status`;
ALTER TABLE `zt_bug` ADD `color` char(7) COLLATE 'utf8_general_ci' NOT NULL AFTER `status`;
ALTER TABLE `zt_case` ADD `color` char(7) COLLATE 'utf8_general_ci' NOT NULL AFTER `status`;
) ENGINE=MyISAM;
ALTER TABLE `zt_task` ADD `color` char(7) NOT NULL AFTER `status`;
ALTER TABLE `zt_story` ADD `color` char(7) NOT NULL AFTER `status`;
ALTER TABLE `zt_bug` ADD `color` char(7) NOT NULL AFTER `status`;
ALTER TABLE `zt_case` ADD `color` char(7) NOT NULL AFTER `status`;