In my DB some tables and columns were defined with collations explicitly:
CREATE TABLE `MyTable` (
`MyTableId` int(11) NOT NULL AUTO_INCREMENT,
`CommandName` varchar(255) COLLATE latin1_general_ci NOT NULL,
PRIMARY KEY (`MyTableId`),
ENGINE=InnoDB AUTO_INCREMENT=64 DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;
Now defined the default charset and collation at database level
ALTER DATABASE `MyDatabase` CHARACTER SET latin1 COLLATE latin1_general_ci;
is it possible to remove the collations (without having to recreate the tables) so it is clear that is using default setting from database. When script the table want to have this instead:
CREATE TABLE `MyTable` (
`MyTableId` int(11) NOT NULL AUTO_INCREMENT,
`CommandName` varchar(255) NOT NULL,
PRIMARY KEY (`MyTableId`),
ENGINE=InnoDB AUTO_INCREMENT=64 DEFAULT CHARSET=latin1;
Tried without specifying the collation value but when script the database is the same
ALTER TABLE MyTable MODIFY CommandName varchar(255)