It takes a long time and effort to analyze a single table when encountering a database that does not have a description of the document.
Fortunately there are some tools that can help us to generate ER diagrams, so it looks at a glance;
Below, I will record one of my own practice, for reference:
1. Download and install the tool:
Download and install MySQL workbench from the website.
: https://www.mysql.com/products/workbench/download completes the direct installation just fine.
For Windows platforms, you may need to install two components (Microsoft. NET Framework 4 Client profile, Visual C + + Redistributable for Visual Studio 2013), reference: H ttp://dev.mysql.com/resources/wb62_prerequisites.html, components:
Visual C + + redistributable for visual Studio 2013:https://www.microsoft.com/en-us/download/details.aspx?id=40784
Microsoft. NET Framework 4 Client profile:http://www.microsoft.com/download/en/details.aspx?id=17113
2. Generating an ER diagram
Next, let Workbench automatically generate ER diagrams based on the structure of the database tables.
2.1 Open Workbench and connect to the database. Through the menu bar "Databas" e--> "Connect to Database", enter the corresponding hostname, port, username, password, and connect successfully;
After the successful connection, you can see the monitoring information, as well as the database tables;
2.2 Through the menu bar "Database", select "Reverse Engineer ...", enter the connection information, and all the way next, finally Excute and close.
You can see that in the Err diagram area more than a map, click on it, you see the ER diagram you want, as for the ER diagram of the connection between the specific relationship.
The resulting ER diagram is as follows, and of course, you can set the size according to your needs:
Export to Picture:
Workbench is very powerful, can also be based on this continue to change, as to how to operate, still need to continue to explore.
The rest of the function, after use, I do Add.
MySQL data table generation ER diagram