简体   繁体   English

MySQL Workbench EER图创建

[英]MySQL Workbench EER diagram creation

There are two issues here regarding MySQL Workbench. 关于MySQL Workbench,这里有两个问题。

Is there a way to update an existing EER diagram with newly created DB tables, so that the EER diagrams automatically reflects the new tables AND their relationships. 有没有一种方法可以使用新创建的数据库表更新现有的EER图,以便EER图自动反映新表及其关系。

OR 要么

Is there a way to auto create the relationships between the table while creating a new EER diagram from an existing database? 从现有数据库创建新的EER图时,是否可以自动创建表之间的关系?

I have about 70 tables in an existing database. 我在现有数据库中大约有70张表。 So creating the relationship links between every table might be quite time consuming and not very productive. 因此,在每个表之间创建关系链接可能会非常耗时且效率不高。

If none of the above is possible, is there any tool out there which would allow me to create an EER diagram with all the relationship paths in place with in the diagram from an existing database. 如果以上都不可行,那么是否有工具可以让我使用现有数据库中的关系图创建所有位置关系路径的EER图。

Use the designer feature of phpmyadmin (version 2.10.0 or newer) . 使用phpmyadmin设计器功能(版本2.10.0或更高版本) It automatically does what you want. 它会自动执行您想要的操作。

Although my MySql-workbench does automatically creates relationship. 尽管MySql-workbench会自动创建关系。

If you can upload the db-dump it would be helpful. 如果您可以上载db-dump,则将很有帮助。

Are you using innodb or MyIASM? 您正在使用innodb还是MyIASM?

If you already have the relationship in your database : the simple way is to export the creation script with mysqldump.exe. 如果您的数据库中已经存在该关系,则简单的方法是使用mysqldump.exe导出创建脚本。 Then in "MySQL Workbench", use the menu File/Import/Reverse Engineer Mysql Create Script. 然后在“ MySQL Workbench”中,使用菜单文件/导入/反向工程师Mysql创建脚本。

The command to execute with mysqldump.exe to export just the structure is : mysqldump -d -uroot -pmypassword databasename > dump.sql 使用mysqldump.exe执行以仅导出结构的命令是:mysqldump -d -uroot -pmypassword数据库名> dump.sql

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM