this post was submitted on 29 Oct 2024
130 points (97.8% liked)

Selfhosted

40218 readers
984 users here now

A place to share alternatives to popular online services that can be self-hosted without giving up privacy or locking you into a service you don't control.

Rules:

  1. Be civil: we're here to support and learn from one another. Insults won't be tolerated. Flame wars are frowned upon.

  2. No spam posting.

  3. Posts have to be centered around self-hosting. There are other communities for discussing hardware or home computing. If it's not obvious why your post topic revolves around selfhosting, please include details to make it clear.

  4. Don't duplicate the full text of your blog or github here. Just post the link for folks to click.

  5. Submission headline should match the article title (don’t cherry-pick information from the title to fit your agenda).

  6. No trolling.

Resources:

Any issues on the community? Report it using the report flag.

Questions? DM the mods!

founded 1 year ago
MODERATORS
 

Hi all, I’m one of the creators of ChartDB.

ChartDB to simplify database design and visualization, providing a powerful, intuitive tool that’s fully open-source. This database diagram tool is similar to traditional ones you can find: dbeaver, dbdiagram, drawsql, etc.

https://github.com/chartdb/chartdb

Key Features:

  • Instant schema import with just one query.
  • AI-powered export to generate DDL scripts for easy database migration.
  • Supports multiple database types: PostgreSQL, MySQL, SQLite, Mssql, ClickHouse and more.
  • Customizable ER diagrams to visualize your database structure.
  • Fully open-source and easy to self-host.

Tech Stack:

  • React + TypeScript
  • Vite
  • ReactFlow
  • Shadcn-ui
  • Dexie.js
top 15 comments
sorted by: hot top controversial new old
[–] cabron_offsets@lemmy.world 5 points 2 weeks ago (1 children)

Looks dope. I’ll give it a try.

[–] johnnyfish@lemmy.world 3 points 2 weeks ago

Lmk how was it pls :) Thank you!

[–] danielquinn@lemmy.ca 4 points 2 weeks ago* (last edited 2 weeks ago) (1 children)

So my first impression is that the requirement to copy-paste that elaborate SQL to get the schema is clever but not sufficiently intuitive. Rather than saying "Run this query and paste the output", you say "Run this script in your database" and print out a bunch of text that is not a query at all but a one-liner Bash script that relies on the existence of pbcopy -- something that (a) doesn't exist on many default installs (b) is a red flag for something that's meant to be self-hosted (why am I talking to a pasteboard?), and (c) is totally unnecessary anyway.

Instead, you could just say: "Run this query and paste the result in this box" and print out the raw SQL only. Leave it up to the user to figure out how they want to run it.

Alternatively you can also do something like: "Run this on your machine and copy/paste the output":

$ curl 'https://app.chartdb.io/superquery.sql' | psql --user USERNAME --host HOSTNAME DBNAME

In the case of the cloud service, it's also not clear if the data is being stored on the server or client side in LocalStorage. I would think that the latter would be preferable.

[–] johnnyfish@lemmy.world 2 points 2 weeks ago

Thanks for the thoughtful feedback, Daniel! You bring up a great point about the complexity of the current approach with the SQL script and the reliance on pbcopy. We’ll definitely consider simplifying it by providing just the raw SQL query, so users can run it in whatever way works best for them. As for the cloud version, we’re leaning towards using LocalStorage for data storage on the client side to keep everything local to the user’s machine, ensuring privacy and control. We’ll make this clearer in the UI and documentation. Appreciate the suggestions - they’re super helpful as we continue refining ChartDB!

[–] kameecoding@lemmy.world 4 points 2 weeks ago (1 children)

Why is this better than DBeaver?

Other than the fact that it mentions AI which makes it instantly infinitely worse?

[–] johnnyfish@lemmy.world 5 points 2 weeks ago

Hey! I get the AI hesitation - it’s everywhere, and I totally understand if you’re wary of buzzwords! With ChartDB, our focus is on making database diagramming simpler, faster, and visually intuitive without the bloat you sometimes find in other tools. The AI component is there mainly to speed up migrations and adapt the tool to specific SQL dialects, so it’s helpful but not in your face.

As for why it might work better for you than DBeaver, ChartDB shines if you’re looking for a minimal, open-source way to visualize schemas quickly without needing a full database management suite. It’s lightweight, community-driven, and designed to do one thing really well: diagram and share schemas with simplicity. Plus, we’re always open to feedback and building features that our community finds valuable!

[–] Flamekebab@piefed.social 3 points 2 weeks ago (1 children)

Amazing, I needed something like that a few months ago (and will need again in future).

[–] johnnyfish@lemmy.world 3 points 2 weeks ago

So happy to read that! Hope you will enjoy and find it as useful as you imagine! Thanks for sharing :)

[–] AustralianSimon@lemmy.world 2 points 2 weeks ago (1 children)

I'll be installing this tonight to give it a go beside dbeaver

[–] johnnyfish@lemmy.world 1 points 2 weeks ago (1 children)

That’s awesome to hear! Thanks for giving ChartDB a shot! We’d love to know how it stacks up for you and if there are any features you think would make it even better. Feel free to reach out here or join our Discord if you have questions or feedback along the way.

[–] AustralianSimon@lemmy.world 2 points 2 weeks ago

Pretty neat. I think its a really nice looking app and helps navigating the database much nicer. I think what is missing for me is some of the power of applications like dbeaver where you can run queries as you go and easily hop between databases.

Also mouse wheel scrolls page not zoom which I think would be better. Definitely will use this next time I build a db in parallel with dbeaver.

[–] Krafting@lemmy.world 2 points 2 weeks ago (1 children)

This looks awesome ! Open-source software needs good design, and you got this right! I might need it in the future, so I'll keep this on my toolbelt :)

[–] johnnyfish@lemmy.world 1 points 2 weeks ago

Thanks a ton! Glad you like the design - keeping it and user-friendly is what we’re all about. We’ll be here whenever you’re ready to give it a spin!

[–] fmstrat@lemmy.nowsci.com 2 points 2 weeks ago (1 children)

Our AI-driven export feature allows you to generate the DDL script in the dialect of your choice.

So many other options without sending my schema to a third party. Why?

[–] johnnyfish@lemmy.world 5 points 2 weeks ago* (last edited 2 weeks ago)

Great question! You don’t have to send anything to a third party - exporting SQL scripts tailored to a specific dialect is optional. By default, we offer a generic SQL export, and only when you need precise, dialect-specific scripts does AI come into play. In the self-hosted version, you’d provide your own OpenAI token, so data stays entirely in your control. Hope that clears it up!