mysql / phpmyadmin 中的关系是否必要

发布于 2024-10-03 03:09:33 字数 178 浏览 0 评论 0原文

我可以在 phpmyadmin/mysql 中创建关系/外键。我的问题是……有必要吗?它主要只是为了我的流程图/组织/注释..或者它实际上对数据库的性能有帮助吗?

另外,当我将数据库导出到 sql 文件时,我没有在任何地方看到任何关系的提及...如果我从该文件重新加载数据库,mysql 将如何恢复它们?

谢谢

I can create relations/foreign keys in phpmyadmin/mysql. My question is...is it necessary? Is it mainly just for my flow-chart / organization / notes..or does it actually help the database in performance?

Also, when I export the database to an sql file, I don't see mention of the relations anywhere...how would mysql recover them if I reloaded the database from this file?

Thanks

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

生来就爱笑 2024-10-10 03:09:33

表之间的关系不是为了性能——而是为了最大限度地减少重复数据并实现业务规则。

mysqldump 文件包含关系 - 它们称为外键,并由 FOREIGN 关键字标识。

Relations between tables aren't for performance -- they're for minimizing duplicated data, and implementing business rules.

mysqldump files include the relationships - they're called foreign keys, and are identified by the FOREIGN keyword.

拥抱我好吗 2024-10-10 03:09:33

我使用 ERwin 或 Nevron 图在数据库中建立一些关系。

通过使用它,我们可以分析一些关系。这样我们就可以防止每个关系中出现任何错误。

i'm use ERwin or Nevron diagram for make some relations in DB.

by using it, we can analize some relation. so we can prevent any mistake in each relation.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文