MySQL Workbench
MySQL Workbench is a ER/database modeling tool for MySQL. You can use it to design and create new database schemas, document existing databases and even perform complex migrations to MySQL.
Main features:
- Cairo based diagramming canvas which allows output to different targets such as OpenGL, Win32, X11, Quartz, PostScript, PDF etc
- visual representation of tables, views, stored procedure/functions and foreign keys
- live database and SQL script file reverse-engineering
- database/model synchronization
- SQL script generation
- extensible architecture
- export as SQL CREATE script
- import DBDesigner4 models
- support for MySQL 5 features
- selectable notations for diagram
[edit] Extending the Workbench
MySQL Workbench can be extended and customized through scripts and plugins. These can be written in languages such as Lua or Python.
Scripts can be used to automate Workbench tasks. You can do things like reverse engineering 100 tables that used to be from an old MySQL 4.0 database, converting all columns that are called 'name' to use UTF8 as their character set and ALTER them in the database. Pretty much everything that Workbench does internally (and more) can be accessed from Workbench plugins, so it can be a very powerful tool. Currently, scripts can be written in the Lua language. Python support will be updated soon.
Plugins are also a very flexible mechanism to extend the Workbench to perform tasks that you need. Since they're easy to develop (if you have some programming or scripting knowledge) you can write plugins to do things like validating your model against a set of company specific conventions/rules, applying changes to all selected tables, autoarranging objects in a layout you like etc. Below is a list of languages that are currently supported:
- Lua
- C/C++
It's possible to add support for new ones, although it will require some C++ coding and some studying of the GRT internals. Support for dynamically loading language support modules is planned.
Reporting Templates allow you to define your own template for generating output based on the database objects in your model. You can generate not only custom reports about your model contents, but also XML DTDs and others. The templating engine used is google-ctemplate.
[edit] Architecture
As with most other MySQL GUI tools, Workbench is divided between native, platform specific GUI frontends and a generic and portable backend. For allowing a richer and smoother user experience, a native user interface frontend is maintained for each major platform (Windows/.NET, Linux/Gtk+ and MacOSX/Cocoa). On the other hand, the common backend is written in such a way that it can be easily extended and reused.
[edit] Also See
- MySQL Workbench FAQ
- Workbench Community Site
- MySQL Workbench Official product page
- Download Workbench Binaries and sources for Windows, Linux and Mac OS X
- Workbench Documentation
