Bug #50720 Synchronization changes character set and collation
Submitted: 29 Jan 2010 9:55 Modified: 4 Feb 2010 16:55
Reporter: Stijn Herreman Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Workbench Severity:S3 (Non-critical)
Version:5.2.14 OS:Windows (7 Ultimate x64)
Assigned to: CPU Architecture:Any
Tags: synchronization

[29 Jan 2010 9:55] Stijn Herreman
Description:
Synchronizing a database will try to change the character set and collation of tables, even when nothing changed.
Snippet below.

ALTER SCHEMA `evenementen_bureau`  DEFAULT CHARACTER SET latin1  DEFAULT COLLATE latin1_swedish_ci ;
ALTER TABLE `evenementen_bureau`.`table1` CHARACTER SET = latin1 , COLLATE = latin1_swedish_ci ;

Workaround: Forward Engineer with DROP selected.
Problem of workaround: only works for empty tables.

How to repeat:
- Create a new model.
- Add a table with at least one field, collation set to Schema Default.
- Forward Engineer the database.
- Immediately after, synchronize the database. The described will happen.

Suggested fix:
Respect the current collation.
[29 Jan 2010 20:40] Johannes Taxacher
when you forward-engineered without the drop statement in the first place, did your tables maybe already exist (with a differnt collation? in that case the alter statement would be expected behaviour ... and it also would explain the "workaround" ... but with a new schema (which doesn't yet exist on the dbserver) i cant repeat your problem.
[29 Jan 2010 20:41] Johannes Taxacher
could you probably provide a dbdump and workbench file for us to reproduce the problem?
[4 Feb 2010 13:37] Stijn Herreman
When I initially made this report, I tested it multiple times and managed to reproduce it every time.
I just tried again and I can't reproduce it any more. Not with my project, not with the steps I posted in my first message.

If you like, you can close this.
[4 Feb 2010 16:55] Johannes Taxacher
ok, closing it then as i cant repeat either.
but thx for the effort to post the report.