Reputation: 759
I have already set-up my database models and for the sake of visualizing my data's, I would like to generate a structure for it. I have installed the required packages which were successful.
List of installed packages for generating the graph using the pip command:
pydot
pyparsing
Graphviz
django-extensions
I was able to generate the dot file successfully by running the command python manage.py graph_models -a > erd.dot
which worked successfully but whenever I used the command python manage.py graph_models -a -g -o erd.png
in order to generate an image for it I get the FileNotFoundError: [WinError 2] "dot" not found in path
error.
Upvotes: 0
Views: 442
Reputation: 39
After many tries and getting the same erros when trying to convert the .dot into a .png I just searched online and found several online tools that did this. I uploaded the .dot file but most of them gave me a PNG that did not have the tables and the lines as they should. This one converted correctly though: https://onlineconvertfree.com/convert/dot/
I also found a github project where you can paste the .dot code in, and it will provide a diagram on the side which can also be downloaded: Link . However, the first link above gave me a better-looking diagram.
Upvotes: -1