The MySQL Workbench can nicely generate a Entity Relationship model from your existing MySQL Database. After Installing click in the column labelled “Data Modelling” on the link below to “Create EER model from existing database”. Follow the wizard to have a generated diagram including your existing tables and their related information. Don’t forget to save the new ER model as *.mwb file.
For Documentation in a project is Confluence as Wiki very good compared to other ones like MediaWiki.
I have written a small plugin to MySQL Workbench as Lua Script to generate Database Model Documentation as Confluence Markup. If you are interested look here for Documentation about the available classes to use in your own scripts.
Part of the generated output from the sample database world from MySQL shown as result in Confluence:
Howto:
- Download this Script here or from github
- Start your MySQL Workbench
- Choose from the “scripting” menu the entry “Install Plugin/Module…”
- Change Drop down in the Dialog to File type “lua Files..”
- Choose downloaded File and click open
- Restart Workbench
- Open previously generated ER model file *.mwb
- Choose from the “Plugins” menu the entry “Catalog” and their the new entry “Confluence Markup Exporter…”
- Markup is now in the clipboard
- Open in Confluence an existing page or create a new onw
- Click on “Edit” button and go to tab “Wiki Markup”
- Paste the generated documentation and click on “save” button