我有一个PostgreSQL数据库。我想从数据库中生成ERD。有没有内置工具或者第三方工具?
当前回答
从https://www.dbvis.com/download/10.0下载DbVisualizer
安装完成后,创建数据库连接:
通过单击ping服务器更改数据库的高亮显示细节和测试。最后点击连接
享受。
其他回答
你可以使用dbeaver来做到这一点。它允许您将ER图导出为png/svg等格式。
德布弗 - https://dbeaver.io/
双击一个模式(例如,模式->公共->表)并打开“ER图”选项卡(在“属性”选项卡旁边)
Open MySQL Workbench. In the home screen click 'Create EER Model From Existing Database'. We are doing this for the case that we have already made the data base and now we want to make an ER diagram of that database. Then you will see the 'Reverse Engineer Database' dialouge. Here if you are asked for the password, provided the admin password. Do not get confused here with the windows password. Here you need to provide the MySQL admin password. Then click on Next. In the next dialouge box, you'll see that the connection to DBMS is started and schema is revrieved from Database. Go next. Now Select the Schema you created earlier. It is the table you want to create the ER diagram of. Click Next and go to Select Objects menu. Here you can click on 'Show Filter' to use the selected Table Objects in the diagram. You can both add and remove tables here.Then click on Execute.
6.当您点击Next和Finish时,所需的ER图就会出现在屏幕上。
为此我们使用了DBVisualizer。
描述: 引用图是一个很好的特性,因为它自动以图形样式呈现所有主键/外键映射(也称为引用完整性约束)。表节点和关系是自动布局的,有许多可用的布局模式。生成的图形是唯一的,因为它以最佳且可读的布局显示所有信息。 来自网站
在我们的许多项目中,我们的团队使用Visual Paradigm从数据库中生成ER图。虽然我们主要在MS SQL和Oracle上工作,但据我所知,他们也支持一些其他的DBMS,如PostgreSQL, MySQL, Sybase, DB2和SQLite。
步骤:
Select Tools > DB > Reverse Database... from the toolbar of Visual Paradigm Keep the settings as is and click Next Select PostgreSQL as driver and provide the driver file there. You can simply click on the download link there to get the driver. Enter the hostname, database name, user and password, and then click Next They will then study your database and lists out the tables in it. Select the table to form an ERD and continue, and that's it. An ERD will be generated with the tables you selected presented.
顺便说一下,它们还支持从ERD生成和更新数据库模式。
希望这能有所帮助。: -)
更多关于从PostgreSQL数据库生成ERD的信息
另一种选择是使用Oracle SQL Developer。分为以下两步:
首先,你需要将SQL Developer连接到PostgreSQL数据库。
然后你可以使用SQL Developer生成一个实体-关系(ER)图
推荐文章
- 将一列的多个结果行连接为一列,按另一列分组
- 我看到VARCHAR(255)如此频繁地使用(而不是其他长度),有什么好的原因吗?
- 使用pgadmin连接到heroku数据库
- 在PostgreSQL中快速发现表的行数
- 更改varchar列的大小为较低的长度
- Delete_all vs destroy_all
- 我如何移动一个redis数据库从一个服务器到另一个?
- 如何首次配置postgresql ?
- 数据库性能调优有哪些资源?
- 如何在PostgreSQL中自动更新时间戳
- 当使用JDBC连接到postgres时,是否可以指定模式?
- 对象'DF__*'依赖于列'*' -将int改为double
- 将映像存储在MongoDB数据库中
- 重复Mongo ObjectId的可能性在两个不同的集合中生成?
- 字符串作为SQL数据库的主键