Bug #73462 | Synchronize Model generate SQL has garbage | ||
---|---|---|---|
Submitted: | 4 Aug 2014 4:25 | Modified: | 21 Aug 2014 0:27 |
Reporter: | Li Yunpeng | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Workbench | Severity: | S3 (Non-critical) |
Version: | 6.1.7 | OS: | MacOS (10.9) |
Assigned to: | CPU Architecture: | Any | |
Tags: | comments, garbage, specical characters, wrap |
[4 Aug 2014 4:25]
Li Yunpeng
[4 Aug 2014 4:53]
MySQL Verification Team
Hello Li Yunpeng, Thank you for the bug report. Verified as described. Thanks, Umesh
[4 Aug 2014 4:59]
MySQL Verification Team
// How to repeat Import the 73462.mwb and try to syn the model and observe sql, confirm the same from synced db // With the sample module, I get below SQL which truncates most of the comments included for the column.. SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0; SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0; SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL,ALLOW_INVALID_DATES'; CREATE SCHEMA IF NOT EXISTS `mydb` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ; CREATE TABLE IF NOT EXISTS `mydb`.`table1` ( `idtable1` INT(11) NOT NULL, `table1col` VARCHAR(45) NULL DEFAULT NULL COMMENT '1,xxx' /* comment truncated */ /*2,xxx 3,xxx*/, `table1col1` VARCHAR(45) NULL DEFAULT NULL COMMENT '1,xxx' /* comment truncated */ /*2,xxx 3,xxx*/, PRIMARY KEY (`idtable1`)) ENGINE = InnoDB DEFAULT CHARACTER SET = utf8 COLLATE = utf8_general_ci; SET SQL_MODE=@OLD_SQL_MODE; SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS; SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;
[4 Aug 2014 5:03]
MySQL Verification Team
Sample model
Attachment: 73462.mwb (application/octet-stream, text), 6.03 KiB.
[21 Aug 2014 0:27]
Philip Olson
Fixed as of the MySQL Workbench 6.2.1 release, and here's the changelog entry: Adding comments for a column in a model would sometimes generate special characters. Thank you for the bug report.