Bug #56183 mydb default db: 1] Use, 2] Incorrect default inclusion & 3] Selection of db
Submitted: 23 Aug 2010 5:26 Modified: 29 Sep 2010 11:55
Reporter: Roel Van de Paar Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Workbench: Modeling Severity:S2 (Serious)
Version:5.2.26 OS:Any
Assigned to: Alfredo Kojima CPU Architecture:Any

[23 Aug 2010 5:26] Roel Van de Paar
Description:
The "mydb" default database is hardcoded into WorkBench:

C:\wb5226src\backend\wbprivate\model\wb_component_physical.cpp: 10177: 
schema->name(StringRef("mydb"));
C:\wb5226src\modules\wb.mysql.import\src\wb_mysql_import_dbd4.cpp: 8380:    (0 <
_catalog->schemata().count()) ? _catalog->schemata().get(0)->name().c_str() : "mydb");
[etc]

There are several issues in relation to this:

1] The name "mydb" may not work as a user may have an existing database named "mydb"
2] In "Create EER model from existing database" option, this database gets "pre-selected" without reason
3] After running "Create EER model from existing database", it is included in the model overview, despite it being specifically deselected in point 2 above

How to repeat:
See video for details
[13 Sep 2010 4:46] Alfredo Kojima
I am not sure this is an issue. You can just delete mydb or rename it to whatever you like.
[13 Sep 2010 20:23] Alfredo Kojima
Ok, after watching the video I realize that the problem is that "Create Model from DB" also includes the mydb default schema. Simply not creating the default mydb schema when creating a model from reveng should be enough to remove the confusion seen in this report.
[13 Sep 2010 20:52] Alfredo Kojima
fixed to not create mydb by default when selecting create model from db or script
[24 Sep 2010 15:34] Johannes Taxacher
fix confirmed in release 5.2.28
[29 Sep 2010 11:55] Tony Bedford
An entry has been added to the 5.2.28 changelog:

The mydb database was created by default when reverse engineering from an existing database or script.