Code Monkey home page Code Monkey logo

manyakrus / image_database Goto Github PK

View Code? Open in Web Editor NEW
7.0 1.0 0.0 16.76 MB

Application for automatically creating a schema for tables and columns in a Postgres database (ERD-diagram). Automatically creating ERD diagrams, display link arrows to the desired column (not only to the table), and have the ability to edit and update the edited diagram

License: GNU General Public License v2.0

Makefile 2.02% Shell 0.21% Python 4.82% Go 92.95%
arrows automatic columns database graph image postgres schema tables update

image_database's Introduction

Applications for automatically creating a schema for tables and columns in a Postgres database (ERD-diagram)

There are many different applications for automatically creating ERD diagrams, however, they all display link arrows only to the table, and not to the desired column, and do not have the ability to edit and update the edited diagram - so I had to create my own application.

The application can automatically find in database and draw:

  1. All tables
  2. All table columns and types
  3. Arrows of table relationships from column to column (foreign key)
  4. Finds tables in the old existing .graphml file, and places the tables at the same X,Y coordinates

The resulting .graphml file in the free yED editor can be:

  1. Export as a .jpg drawing
  2. Edit
  3. Automatic placement of blocks

A sample implementation (drawings) can be found in the examples directory

Installation procedure:

  1. Install the .graphml file editor yEd (free) https://www.yworks.com/products/yed/download

  2. Compile this repository

make build

the image_database file will appear in the bin folder

  1. make a .env file with filled parameters:
FILENAME_GRAPHML=
INCLUDE_TABLES=
EXCLUDE_TABLES=

DB_HOST=
DB_NAME=
DB_SCHEME=
DB_PORT=
DB_USER=
DB_PASSWORD=

Run image_database file

  1. Open the resulting .graphml file in the yEd editor (all elements will first be in the center of the screen) and select from the menu: Tools - Remove Node Overlaps
  • the yEd editor will arrange all the elements of the diagram in the optimal form.
  1. Export the diagram to an image. Select from the menu: File - Export

database

Source code in Golang language. Tested on Linux Ubuntu Readme from 09/14/2023

Made by Alexander Nikitin https://github.com/ManyakRus/image_database

image_database's People

Contributors

manyakrus avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.