Bug #39060 workbench synchronize fails
Submitted: 27 Aug 2008 1:48 Modified: 15 Oct 2009 9:37
Reporter: Michael Tibben Email Updates:
Status: Duplicate Impact on me:
None 
Category:MySQL Workbench Severity:S2 (Serious)
Version:5.0.24 OS:Windows
Assigned to: CPU Architecture:Any

[27 Aug 2008 1:48] Michael Tibben
Description:
Synchronization to mysql-server-5.0.45 fails when using Database->Synchronize on my model.

The model does not report any validation issues when using Model->Validation->Validate All or Model->Validation(MySQL)->Validate All.

Further to this, the create script generated also fails when using File->Export->Forward Engineer SQL Create Script.

Some of the SQL errors I have picked up:
 - BOOLEAN type tries to get created as BOOLEAN(2)
 - INSERT statements fail
 - incorrect collations set when using the Schema default
 - foreign keys do not get created correctly

How to repeat:
Open workbench file.
Try to synchronize with an empty database. 
SQL errors occur.

Open workbench file.
Generate SQL Create Script
Run script on MySQL
SQL errors occur.
[27 Aug 2008 3:49] Valeriy Kravchuk
I had tried to generate and run create script with MySQL 5.0.67. The only problem I've got is with the view:

mysql> CREATE  OR REPLACE VIEW `cdwow_u`.`u_stock_price` AS
    -> SELECT product_code, currency_to, base_price*markup_multiplier*currency_m
ultiplier
    -> FROM new_products
    -> INNER JOIN `u_dropshipper` USING (`dropshipper_id`)
    -> LEFT JOIN `u_currency_conversion` ON `base_price_currency`=`currency_from
`;
ERROR 1054 (42S22): Unknown column 'dropshipper_id' in 'from clause'

I do not see dropshipper_id column in the new_products table, so this error message is expected.

I was not able to identify BOOLEAN(2) or other problems you described with your file uploaded. Please, check if this is really the file that gives you all the problems mentioned.
[27 Aug 2008 23:44] Michael Tibben
The problem is actually in the synchronize feature, not the create script.

Attached is the synchronize file when trying to synchronize with an empty database.
[27 Aug 2008 23:57] Michael Tibben
When I attempt to synchronize with a db which has been created with the correct create sql generated from workbench (and therefore should not need synchronization), the synch feature produces a buggy SQL file.
[12 Sep 2008 11:31] Valeriy Kravchuk
Thank you for a problem report. Please, try to repeat with a newer version, 5.0.25, and inform about the results.
[12 Oct 2008 23:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[15 Oct 2009 9:37] Susanne Ebrecht
This is a duplicate of bug #47953.

I will set this bug here as duplicate because the other has a better test description.