i cannot find any free sql documentation tool
最近,需要给 MySQL 数据库做一个说明文档,想仿照 http://codex.wordpress.org/Database_Description 页面中的 Table Overview 和 Detail 样式用软件自动生成(在 Google 上发现此类软件大多叫做 sql documentation tool)。
只是我找了两天都没有发现合适的软件,很多都只适用于 Oracle、SQL Server、JDBC 数据库,针对 MySQL 而开发的很少,有几个也是属于商业软件,例如 Dbscribe for MySQL 之前也有免费的 1.1 版本,可惜找到的几个网上链接都是指向其官方网站,而其官方网站早就狡猾地把标明为 dbcrim11.zip 文件中的内容更改为 1.3 的商业版本,更可气 的是在Vista中试用时根本就无法连接 MySQL 数据库。
百度上也看到有用 Word VBA 开发了相关的 MySQL 数据库结构自动文档化工具。,但我不愿为了此而安装盗版的 Office 软件(正版的我作为个人用户消费不起,如果公司能购买的话我不介意使用)。
看来这次我想偷懒的想法泡汤了,可惜正版的 Dbscribe for MySQL 售价 39美元,显然不符合咱的消费水平,如果换成人民币且能在 Vista 环境下使用,我可以掏出钱来购买这一软件。
其网址为 http://www.leadum.com.nyud.net/product.php?prod_id=4 ,需要翻墙才能访问,网监处的人脑子真是坏了,连这种网站都被屏蔽了…
DBScribe 1.3 for MySQL
Product summary
MySQL database documentation tool that creates precise technical documentation of every detail of a database schema within a moment.
DBScribe prevents your staff from long routing documenting work and synchronization with database changes, gives you team members precise database documentation, increases your customer satisfaction with complete, professional looking database description.
DBScribe supports wide range of output formats (Microsoft HTML Help format (CHM), single HTML, multiple file HTML site and Microsoft Word document), rich set of features to customize you documentation, all SQL objects documenting, wizard and command line interface.
惊喜的发现,原来在 phpMyAdmin 的导出文件类型中选择 Open Document Text 或 Microsoft Word 2000 就可以达到我的要求了,我之前只试过 SQL,CSV,Open Document Spreadsheet,PDF 这几种类型后就放弃了。
如下图:
不过,首先还是需要在修改数据结构的 Comments 文本框中加上说明文字才行,
然后,在选择 Open Document Text 并且不要导出 Data,
最后,打开生成的 odt文件。
稍有遗憾遗憾的是,phpMyAdmin 无法导出如 Table comments 的内容,更加无法对数据库进行注释,以后如果能自动在生成的文档中增加目录索引就更好了,最好是 MySQL 官方的 Workbench 软件以后能集成数据库结构文档生成工具而不是仅能生成暂时对我毫无用处的数据库模型。




写的很高深呢 研究透彻了吗
@卢松松
略窥门径吧,毕竟花了这么多时间来解决这一问题。