Closed philCryoport closed 6 years ago
Good idea. I will look at a way to do this.
Hi there! I see you implemented code and code-tests for this feature. Thank you.
When you have a moment -- and if you haven't already -- would you please update the documentation so I can have example commands to model?
Thanks.
Phil, I am trying to get you a release as soon as possible. :smile:
Sorry, don't mean to rush you 8) I saw the commit and wanted to help...
Please use the latest release, v14.20.06. You can find documentation on the SchemaCrawler diagramming page.
@philCryoport - did this work for you?
With schemacrawler-14.20.06-distribution on Windows 10, adding the following two lines to schemacrawler.config.properties
:
schemacrawler.graph.graphviz.graph.ranksep=1.0
schemacrawler.graph.graphviz.graph.splines=polyline
Works great with:
-outputformat=scdot
or -outputformat=dot
, anddot -T pdf graph.dot -O
PDF has no errors and at initial glance does seem complete.
Now, if I then add the following in addition to schemacrawler.config.properties
:
schemacrawler.graph.graphviz.graph.nodesep=1.0
...I get the following error message when I open the PDF in Adobe Reader DC:
...and the top of the diagram cuts off:
id INT NOT NULL
auto-incremented
a_column INT
b_column INT
c_column INT
A diff of the dot files generated with and without the nodesep line shows:
(and later on a comparison of generated on
dates but that doesn't matter in this case)
Thanks for testing. The problem you describe is a Graphviz or Adobe Acrobat issue, and outside of SchemaCrawler. I would suggest trying to open the PDF file in Foxit PDF Reader to see if you get better results.
Indeed it does open without complaint or any at-first-glance visual problems in Foxit Reader :)
Thank you for adding the feature!
Glad it worked for you.
Environment
version of SchemaCrawler that you are using schemacrawler-14.20.04-distribution
version of Java that you are using java version "1.8.0_161" Java(TM) SE Runtime Environment (build 1.8.0_161-b12) Java HotSpot(TM) 64-Bit Server VM (build 25.161-b12, mixed mode)
operating system and version that you are using Windows 10 Version 1709 (OS Build 16299.371) 64-bit
relational database and version that you are using MySQL 5.7.21 (AWS RDS)
JDBC driver and version that you are using 04/19/2018 02:04 PM 825,389 mssql-jdbc-6.2.2.jre8.jar 04/19/2018 02:04 PM 2,001,778 mysql-connector-java-6.0.6.jar (came with SchemaCrawler release)
Other relevant libraries: 03/16/2017 09:36 AM 41,203 slf4j-api-1.7.25-jar.jar (came with SchemaCrawler release) 01/14/2018 11:09 AM 993,917 graphviz-java-0.2.3-jar.jar 01/14/2018 11:09 AM 661,033 graphviz-java-0.2.3-source.jar (downloaded the GraphViz native Java libraries using the SchemaCrawler download tool.)
Issue
I use SchemaCrawler to
-server=mysql -portablenames -Gdpi=300 -outputformat=scdot
. With the large number of tables and foreign key relationships in my database, this results in a diagram with many near-overlapping edges.It would be great to be able to provide a configuration file that would allow me to alter the
dot
default values for:And add a value for:
Right now it requires me to output a
dot
file and then manually edit thatdot
output file to do a change like this:to this:
It looks like the
dot
values are hard-coded in https://github.com/schemacrawler/SchemaCrawler/blob/master/schemacrawler-tools/src/main/resources/dot.header.txtWould you please update the SchemaCrawler application accordingly?
Thanks!