schemacrawler 未在 MS sql 服务器数据库的图形选项中显示 relationships/edges

schemacrawler not showing relationships/edges in graph option for MS sql server db

我一直在尝试绘制 SQL 服务器数据库中表子集中的关系图。

我 运行 sc.sh 在 MAC OS 上使用以下选项:

-server=sqlserver -host=<host> -database=<schema> -user=<user> -password=<password> -infolevel="maximum" -command="graph" -schemas=<schema> -tables="<database>\.<schema>\.TABLE1|<database>\.<schema>\.TABLE2" -grepcolumns=".*\.PRIMARYKEY" -tabletypes=TABLE -outputformat=pdf -outputfile=diagram.pdf

我使用的 graphviz 版本是 2.28.0(如果我使用比这个版本更高的版本,我在 schemacrawler 和 schemaSpy 中都会出错)。

当我 运行 命令时,我得到了输出 pdf 文件。但它只包含 tables/nodes 及其列,没有应该 link 2 个表的 relationship/edge。

我还尝试为数据库中的所有表生成图表,输出再次是所有 tables/nodes 及其列的图表,但没有任何 relationships/edges。

我可以 运行 作为架构爬虫下载的一部分的图表示例,输出确实显示了 relationships/edges。

最后,我可以在 schemaSpy 中生成显示正确关系的图表。我想看看是否可以在 schemacrawler 中为一组特定的表和列生成图表。

我使用 schemacrawler-12.04.02-main

Thomas,请使用 SchemaCrawler 12.05.02 或更高版本。用于检测弱关系或隐含关系的算法已得到增强,您现在应该可以在图表中看到您想要看到的边。

苏阿莱赫·法塔希,SchemaCrawler