Use the File menu to open a project, begin a
new project, or save a project. Choosing New
Model opens the default schema,
mydb. Choosing Open
Model opens a file dialog box with the default file
type set to MySQL Workbench Models (
extension). To display a list of recently opened MWB files, choose
the Open Recent menu item. The keyboard
shortcut to create a new project is Control+N and
the command to open an existing project is
To close the currently active
MySQL Model or
EER Diagram tab, use the Close
Tab menu item. You can also do this from the
keyboard by pressing Control+W. To reopen the
MySQL Model tab, see
Section 188.8.131.52, “The View Menu”. To reopen an
Diagram tab, double-click the
Diagram icon in the
section of the
MySQL Model page.
Use the Save Model or Save
Model As 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
Use the Import 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
schema objects are copied to the default schema,
If the script creates a database, a new tab bearing the
database name is added to the
Schemata section of the
If the script contains data, the data is ignored.
For details about importing a DDL script, see Section 184.108.40.206, “Reverse Engineering Using a Create Script”.
Under the Import submenu, you can also
There are variety of items under the Export 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 220.127.116.11, “Forward Engineering Using an SQL Script”.
Using the Export 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 Page Setup 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 Document Properties menu item to set the following properties of your project:
Name: The model name (default is
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