Use the menu to open a project, begin a
new project, or save a project. Choosing opens the default schema,
mydb. Choosing opens a file dialog box with the default file
type set to MySQL Workbench Models (mwb
extension). To display a list of recently opened MWB files, choose
the menu item. The keyboard
shortcut to create a new project is Control+N and
the command to open an existing project is
Control+O.
To close the currently active MySQL Model or
EER Diagram tab, use the menu item. You can also do this from the
keyboard by pressing Control+W. To reopen the
MySQL Model tab, see
Section 7.5.1.3, “The View Menu”. To reopen an EER
Diagram tab, double-click the EER
Diagram icon in the EER Diagrams
section of the MySQL Model page.
Use the or menu items to save a model. When you save a
model, its name appears in the title bar of the application. If
you have made changes to a project and have not saved those
changes, an asterisk appears in the title bar following the model
name. When you save a model, it is saved as a MySQL Workbench file
with the extension mwb.
Use the menu item to import a
MySQL data definition (DDL) script file. For example, this might
be a file created by issuing the command mysqldump
--no-data. MySQL Workbench handles the
script as follows:
If the script does not contain a CREATE DATABASE
statement, the
schema objects are copied to the default schema,
db_name;mydb.
If the script creates a database, a new tab bearing the
database name is added to the Physical
Schemata section of the MySQL
Model page.
If the script contains data, the data is ignored.
For details about importing a DDL script, see Section 7.7.9.1, “Reverse Engineering Using a Create Script”.
Under the submenu, you can also
import DBDesigner4 files.
There are variety of items under the submenu. You may generate the SQL statements necessary to create a new database or alter an existing one. For more information about these menu items, see Section 7.7.10.1, “Forward Engineering Using an SQL Script”.
Using the submenu, you can also
export an EER diagram as a PNG, SVG, PDF, or Postscript file. For
an example of a PNG file, see
Figure 7.50, “The sakila Database EER Diagram”.
The menu item enables you to set the paper size, orientation, and margins for printing purposes.
The printing options are enabled only if the EER Diagrams tab is selected. You have the choice of printing your model directly to your printer, printing it as a PDF file, or creating a PostScript file. For more information, see Section 7.9, “Printing”.
The printing options are available only in commercial versions of MySQL Workbench.
Use the menu item to set the following properties of your project:
Name: The model name (default is
MySQL Model)
Version: The project version number
Author: The project author
Project: The project name
Created: Not editable; determined by the
MWB file attributes
Last Changed: Not editable; determined by
the MWB file attributes
Description: A description of your project