Bug #41254 | invisible characters in reverse engineered script cause problems on fwd eng | ||
---|---|---|---|
Submitted: | 5 Dec 2008 10:56 | Modified: | 10 Jun 2009 15:33 |
Reporter: | Van Stokes | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Workbench | Severity: | S2 (Serious) |
Version: | 5.0.27 SE | OS: | Windows (Vista SP1) |
Assigned to: | Sergei Tkachenko | CPU Architecture: | Any |
Tags: | CHECKED, forward engineer, workbench |
[5 Dec 2008 10:56]
Van Stokes
[5 Dec 2008 12:40]
MySQL Verification Team
Thank you for the bug report.
[8 Dec 2008 8:23]
Van Stokes
Well, we think we found the issue. We reversed engineered our database with an older version of the Workbench. There was a lot nasty hidden control characters in the text. Not visible in WorkBench but when we copy and pasted the data to a text editor and turned on "show all" it became quite clear what the problem was. Sorry for the false alarm.
[8 Dec 2008 8:30]
Mike Lischke
Thank you Van, though I think WB should nontheless be robust against such problems and at least produce a usefull error message, thus reopening the report.
[4 Jun 2009 19:11]
Alfredo Kojima
changed the description
[4 Jun 2009 19:28]
Alfredo Kojima
Problem seems to be that SQL code in reverse engineered objects contain a mix of \n, \r and \r\n line breaks. Reverse engineering code should normalize line breaks in SQL code (triggers, views, SPs) to \n only. Validation should also check SQL code objects for invalid linebreaks.
[9 Jun 2009 15:07]
Sergei Tkachenko
Added normalization of line-breaks before reverse engineering of SQL.
[9 Jun 2009 19:27]
Johannes Taxacher
handling of line-break characters fixed now in 5.1. will be included in 5.1.13
[10 Jun 2009 15:33]
Tony Bedford
An entry was added to the 5.1.13 changelog: Invisible characters in a reverse engineered script caused errors to be generated when the same script was forward engineered. The problem was due to the reverse engineered script containing a mixture of \n, \r and \r\n line endings. These are now normalized to \n in the reverse engneering code. The validation process now also checks SQL code objects to ensure valid line endings.